]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
fix alias execution order bug introduced by Black on 20050705 (using Cbuf_AddText...
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Wed, 22 Feb 2006 23:18:12 +0000 (23:18 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Wed, 22 Feb 2006 23:18:12 +0000 (23:18 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6004 d7cf8633-e32d-0410-b094-e92efae38249

cmd.c

diff --git a/cmd.c b/cmd.c
index bc09a50d629f3b24f73958a84447e060467565c2..2af8f84c6ef50f6c6648dd3bf94367686eee5157 100644 (file)
--- a/cmd.c
+++ b/cmd.c
@@ -502,7 +502,9 @@ static void Cmd_ExecuteAlias (cmdalias_t *alias)
 {
        static char buffer[ MAX_INPUTLINE + 2 ];
        Cmd_PreprocessString( alias->value, buffer, sizeof(buffer) - 2, alias );
-       Cbuf_AddText( buffer );
+       // insert at start of command buffer, so that aliases execute in order
+       // (fixes bug introduced by Black on 20050705)
+       Cbuf_InsertText( buffer );
 }
 
 /*