]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - console.c
patch from div0 to fix issues with libcurl on old nexuiz servers
[xonotic/darkplaces.git] / console.c
index 75beb33032079366cb0835325e02e6fb7edcb300..97f6526b8dd6582427c372124cd5f464f84625f5 100644 (file)
--- a/console.c
+++ b/console.c
@@ -636,7 +636,12 @@ void Con_Print(const char *msg)
                        {
                                // play talk wav
                                if (*msg == 1)
-                                       S_LocalSound ("sound/misc/talk.wav");
+                               {
+                                       if (msg[1] == '(' && cl.foundtalk2wav)
+                                               S_LocalSound ("sound/misc/talk2.wav");
+                                       else
+                                               S_LocalSound ("sound/misc/talk.wav");
+                               }
                                line[index++] = STRING_COLOR_TAG;
                                line[index++] = '3';
                                msg++;
@@ -1224,7 +1229,7 @@ qboolean GetMapList (const char *s, char *completedname, int completednamebuffer
                                goto endcomplete;
        }
 endcomplete:
-       if(p > o)
+       if(p > o && completedname && completednamebufferlength > 0)
        {
                memset(completedname, 0, completednamebufferlength);
                memcpy(completedname, (t->filenames[0]+5), min(p, completednamebufferlength - 1));