This is patch01 to PennMUSH 1.7.6. After applying this patch, you will have version 1.7.6p1 To apply this patch, save it to a file in your top-level MUSH directory, and do the following: patch -p1 < 1.7.6-patch01 make install If you use GNU patch 2.2, you probably want the above to be 'patch -b -p1', not just 'patch -p1'. Unix (or cygwin) users need not worry about failed hunks in src/switchinc.c, hdrs/switches.h, hdrs/cmds.h, or hdrs/funs.h. These files are automatically rebuilt on compile. Then @shutdown and restart your MUSH. If you had set use_dns to 'off' in mush.cnf and are using INFO_SLAVE, you will want to do a full @shutdown, rather than simply @shutdown/reboot. - Alan/Javelin In this patch: Minor changes: * When using @nuke to destroy a SAFE object when really_safe is "no", provide a warning (but schedule destruction anyway). Suggested by Cerekk@bDV. Fixes: * VS.NET project file was defaulting to signed instead of unsigned chars, causing crashes. Fixed by BladedThoth@M*U*S*H. Several places where we should have cast things to unsigned to avoid this kind of thing have been fixed. [SW] * The *emit() functions now set the orator correctly. Reported by Philip Mak. * ccom and cplr are cleared after each command execution so they can't be leaked as easily. Suggested by Philip Mak. * Linting. * If God gives the wrong password to @logwipe, provide some feedback. Suggested by Cerekk@bDv. * mkcmds.sh was needlessly rebuilding several autogenerated files. * The rules for flag characters shown in object headers now allows F_INTERNAL flags to be shown (like GOING), just the same as when you get a full flag list on examine. Report by Philip Mak. * Help fixes by Bird@M*U*S*H, Intrevis@M*U*S*H, Philip Mak. * @search type=something would report an error AND match the entire database when something wasn't object, player, exit or room. [SW] * Cosmetic bug in @malias/list fixed. Report by Philip Mak. * The info_slave now properly obeys the use_dns setting in mush.cnf. This requires a full shutdown to put into effect. Report by BlaZe@M*U*S*H. [SW] Prereq: 1.7.6p0 *** 1_7_6.36/Patchlevel Mon, 11 Nov 2002 20:59:15 -0600 dunemush (pennmush/5_Patchlevel 1.17.1.11.1.1 600) --- 1_7_6.56(w)/Patchlevel Sun, 08 Dec 2002 22:45:53 -0600 dunemush (pennmush/5_Patchlevel 1.17.1.11.1.1.1.1 600) *************** *** 1,2 **** Do not edit this file. It is maintained by the official PennMUSH patches. ! This is PennMUSH 1.7.6p0 --- 1,2 ---- Do not edit this file. It is maintained by the official PennMUSH patches. ! This is PennMUSH 1.7.6p1 *** 1_7_6.36/CHANGES Tue, 26 Nov 2002 14:28:59 -0600 dunemush (pennmush/g/17_CHANGES 1.10.1.6.1.2 600) --- 1_7_6.56(w)/CHANGES Sun, 08 Dec 2002 22:34:55 -0600 dunemush (pennmush/g/17_CHANGES 1.10.1.6.1.2.1.2.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1 600) *************** *** 18,23 **** --- 18,54 ---- ========================================================================== + Version 1.7.6 patchlevel 1 November 26, 2002 + + Minor changes: + * When using @nuke to destroy a SAFE object when really_safe is "no", + provide a warning (but schedule destruction anyway). Suggested by + Cerekk@bDV. + Fixes: + * VS.NET project file was defaulting to signed instead of unsigned + chars, causing crashes. Fixed by BladedThoth@M*U*S*H. + Several places where we should have cast things to unsigned to + avoid this kind of thing have been fixed. [SW] + * The *emit() functions now set the orator correctly. + Reported by Philip Mak. + * ccom and cplr are cleared after each command execution so they + can't be leaked as easily. Suggested by Philip Mak. + * Linting. + * If God gives the wrong password to @logwipe, provide some feedback. + Suggested by Cerekk@bDv. + * mkcmds.sh was needlessly rebuilding several autogenerated files. + * The rules for flag characters shown in object headers now allows + F_INTERNAL flags to be shown (like GOING), just the same as + when you get a full flag list on examine. Report by Philip Mak. + * Help fixes by Bird@M*U*S*H, Intrevis@M*U*S*H, Philip Mak. + * @search type=something would report an error AND match the entire + database when something wasn't object, player, exit or room. [SW] + * Cosmetic bug in @malias/list fixed. Report by Philip Mak. + * The info_slave now properly obeys the use_dns setting in mush.cnf. + This requires a full shutdown to put into effect. Report by + BlaZe@M*U*S*H. [SW] + + Version 1.7.6 patchlevel 0 November 11, 2002 License: *** 1_7_6.36/game/txt/hlp/pennvers.hlp Tue, 26 Nov 2002 14:28:59 -0600 dunemush (pennmush/12_pennvers.h 1.169.1.42.1.3.1.2.2.2.1.1.1.3.1.1.1.5.1.4.1.1.1.1.1.1.1.1.1.5.1.1.1.3.1.1.1.3.1.1.1.54.1.10.1.2 600) --- 1_7_6.56(w)/game/txt/hlp/pennvers.hlp Sun, 08 Dec 2002 22:35:09 -0600 dunemush (pennmush/12_pennvers.h 1.169.1.42.1.3.1.2.2.2.1.1.1.3.1.1.1.5.1.4.1.1.1.1.1.1.1.1.1.5.1.1.1.3.1.1.1.3.1.1.1.54.1.10.1.2.1.1.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.2.1.1.1.1 600) *************** *** 1,5 **** & changes ! & 1.7.6p0 This is a list of changes in this patchlevel which are probably of interest to players. More information about new commands and functions can probably be gotten via 'help '. 'help credits' --- 1,5 ---- & changes ! & 1.7.6p1 This is a list of changes in this patchlevel which are probably of interest to players. More information about new commands and functions can probably be gotten via 'help '. 'help credits' *************** *** 11,16 **** --- 11,48 ---- A list of the patchlevels associated with each release can be read in 'help patchlevels'. + Version 1.7.6 patchlevel 1 November 26, 2002 + + Minor changes: + * When using @nuke to destroy a SAFE object when really_safe is "no", + provide a warning (but schedule destruction anyway). Suggested by + Cerekk@bDV. + Fixes: + * VS.NET project file was defaulting to signed instead of unsigned + chars, causing crashes. Fixed by BladedThoth@M*U*S*H. + Several places where we should have cast things to unsigned to + avoid this kind of thing have been fixed. [SW] + * The *emit() functions now set the orator correctly. + Reported by Philip Mak. + * ccom and cplr are cleared after each command execution so they + can't be leaked as easily. Suggested by Philip Mak. + * Linting. + * If God gives the wrong password to @logwipe, provide some feedback. + Suggested by Cerekk@bDv. + * mkcmds.sh was needlessly rebuilding several autogenerated files. + * The rules for flag characters shown in object headers now allows + F_INTERNAL flags to be shown (like GOING), just the same as + when you get a full flag list on examine. Report by Philip Mak. + * Help fixes by Bird@M*U*S*H, Intrevis@M*U*S*H, Philip Mak. + * @search type=something would report an error AND match the entire + database when something wasn't object, player, exit or room. [SW] + * Cosmetic bug in @malias/list fixed. Report by Philip Mak. + * The info_slave now properly obeys the use_dns setting in mush.cnf. + This requires a full shutdown to put into effect. Report by + BlaZe@M*U*S*H. [SW] + + + & 1.7.6p0 Version 1.7.6 patchlevel 0 November 11, 2002 License: *************** *** 5715,5721 **** For information on a specific patchlevel of one of the versions listed, type 'help p'. For example, 'help 1.7.2p3' ! 1.7.6: 0 1.7.5: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 1.7.4: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20 --- 5747,5753 ---- For information on a specific patchlevel of one of the versions listed, type 'help p'. For example, 'help 1.7.2p3' ! 1.7.6: 0, 1 1.7.5: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 1.7.4: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20 *** 1_7_6.36/game/txt/hlp/pennfunc.hlp Tue, 26 Nov 2002 14:28:59 -0600 dunemush (pennmush/16_pennfunc.h 1.2.1.50.1.1.1.1.1.2.1.7.1.8.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.1 600) --- 1_7_6.56(w)/game/txt/hlp/pennfunc.hlp Mon, 02 Dec 2002 18:13:48 -0600 dunemush (pennmush/16_pennfunc.h 1.2.1.50.1.1.1.1.1.2.1.7.1.8.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.1.1.1 600) *************** *** 1474,1480 **** This inserts before the item of at the . That means that then becomes the th element of ! . If a separator is not given, a space is assumed. Examples: > say [insert(This is a string,4,test)] --- 1474,1481 ---- This inserts before the item of at the . That means that then becomes the th element of ! . If a separator is not given, a space is assumed. Null items are ! counted when determining position, as in 'items()'. Examples: > say [insert(This is a string,4,test)] *************** *** 1678,1684 **** Ldelete(,[,]) This deletes the item at in the list. If a separator ! character is not given, a space is assumed. Examples: > say [ldelete(This is a long test string,4)] --- 1679,1686 ---- Ldelete(,[,]) This deletes the item at in the list. If a separator ! character is not given, a space is assumed. Null items are ! counted, as in 'items()'. Examples: > say [ldelete(This is a long test string,4)] *************** *** 2615,2621 **** replace(,,[,]) This replaces the item at of with . ! If no separator is given, a space is assumed. Examples: > say [replace(Turn north at the junction,2,south)] --- 2617,2624 ---- replace(,,[,]) This replaces the item at of with . ! If no separator is given, a space is assumed. Null items are ! counted when determining position, as in 'items()'. Examples: > say [replace(Turn north at the junction,2,south)] *** 1_7_6.36/game/txt/hlp/pennflag.hlp Wed, 20 Nov 2002 21:46:44 -0600 dunemush (pennmush/17_pennflag.h 1.1.1.1.1.2.1.1.1.2.1.1.1.2.1.1.2.1.2.1.1.1.1.2.1.4 600) --- 1_7_6.56(w)/game/txt/hlp/pennflag.hlp Tue, 03 Dec 2002 21:40:42 -0600 dunemush (pennmush/17_pennflag.h 1.1.1.1.1.2.1.1.1.2.1.1.1.2.1.1.2.1.2.1.1.1.1.2.1.4.1.1 600) *************** *** 663,669 **** See also: ROYALTY, @power & Z_TEL ! Flag: Z_TEL (all types) The Z_TEL flag, when set on a zoned room or on the ZMO of a room, prevents objects in the room from being @teleported out of the --- 663,669 ---- See also: ROYALTY, @power & Z_TEL ! Flag: Z_TEL (things, rooms) The Z_TEL flag, when set on a zoned room or on the ZMO of a room, prevents objects in the room from being @teleported out of the *** 1_7_6.36/game/txt/hlp/penncmd.hlp Wed, 20 Nov 2002 09:43:49 -0600 dunemush (pennmush/18_penncmd.hl 1.2.1.1.1.47.1.1.1.1.1.3.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.10 600) --- 1_7_6.56(w)/game/txt/hlp/penncmd.hlp Mon, 09 Dec 2002 10:15:09 -0600 dunemush (pennmush/18_penncmd.hl 1.2.1.1.1.47.1.1.1.1.1.3.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.10.1.1.1.1 600) *************** *** 2257,2263 **** If the = part is omitted, the message will be reset. ! See also: & @oxtport @oxtport [=] --- 2257,2263 ---- If the = part is omitted, the message will be reset. ! See also: leave, @leave, @oleave, @aleave & @oxtport @oxtport [=] *************** *** 3128,3134 **** The second form of the command runs @wcheck on every object in the database and informs connected owners of warnings. It is usually automatically run by the MUSH at intervals. Only Wizards may use ! @wheck/all. The third runs it on all objects the player owns that aren't set NO_WARN. --- 3128,3134 ---- The second form of the command runs @wcheck on every object in the database and informs connected owners of warnings. It is usually automatically run by the MUSH at intervals. Only Wizards may use ! @wcheck/all. The third runs it on all objects the player owns that aren't set NO_WARN. *** 1_7_6.36/game/mushcnf.dst Wed, 30 Oct 2002 23:34:53 -0600 dunemush (pennmush/41_mushcnf.ds 1.1.1.19.1.1.1.2.1.1.1.8 600) --- 1_7_6.56(w)/game/mushcnf.dst Sun, 08 Dec 2002 22:32:42 -0600 dunemush (pennmush/41_mushcnf.ds 1.1.1.19.1.1.1.2.1.1.1.8.1.1 600) *************** *** 27,32 **** --- 27,34 ---- # If yes, you'll see hostnames on the wizard WHO. If no, IP numbers. # No makes sense if you're running PennMUSH at home and don't have # a DNS server you can access. MacOS 7/8/9 should use 'no' + # Changing this while using info_slave requires a @shutdown/reboot + # to make it take effect. use_dns yes # Databases *************** *** 347,352 **** --- 349,356 ---- ### and select an ident_timeout to determine how long the MUSH ### should wait for a response, in seconds. If you're using ### INFO_SLAVE (in options.h), this is how long the info_slave waits. + # Changing this while using info_slave requires a @shutdown/reboot + # to make it take effect. use_ident yes ident_timeout 5 *** 1_7_6.36/utils/mkcmds.sh.SH Mon, 30 Sep 2002 23:28:28 -0500 dunemush (pennmush/g/16_mkcmds.sh. 1.1 750) --- 1_7_6.56(w)/utils/mkcmds.sh.SH Sat, 30 Nov 2002 22:32:31 -0600 dunemush (pennmush/g/16_mkcmds.sh. 1.2 750) *************** *** 109,154 **** $echo "You have too many switches defined!" fi ! cmp -s ../hdrs/switches.h ../hdrs/temp.h ! cmpstat=$? ! if [ $cmpstat -eq 0 ]; then ! rm -f ../hdrs/temp.h ! else ! mv -f ../hdrs/temp.h ../hdrs/switches.h ! fi ! cmp -s ../src/switchinc.c ../src/temp.c ! cmpstat=$? ! if [ $cmpstat -eq 0 ]; then ! rm -f ../src/temp.c ! else ! mv -f ../src/temp.c ../src/switchinc.c ! fi $echo "Rebuilding command prototype file" $echo "/* AUTOGENERATED FILE. DO NOT EDIT */" >> ../hdrs/temp.h for c in `grep "^COMMAND *(" ../src/*.c | cut -f2 -d\( | cut -f1 -d\) | sort | uniq`; do $echo >>../hdrs/temp.h "COMMAND_PROTO($c);" done ! cmp -s ../hdrs/cmds.h ../hdrs/temp.h ! cmpstat=$? ! if [ $cmpstat -eq 0 ]; then ! rm -f ../hdrs/temp.h ! else ! mv -f ../hdrs/temp.h ../hdrs/cmds.h ! fi $echo "Rebuilding function prototype file" $echo "/* AUTOGENERATED FILE. DO NOT EDIT */" >> ../hdrs/temp.h for c in `grep "^FUNCTION *(" ../src/*.c | cut -f2 -d\( | cut -f1 -d\) | sort | uniq`; do $echo >>../hdrs/temp.h "FUNCTION_PROTO($c);" done ! cmp -s ../hdrs/funs.h ../hdrs/temp.h ! cmpstat=$? ! if [ $cmpstat -eq 0 ]; then ! rm -f ../hdrs/temp.h ! else ! mv -f ../hdrs/temp.h ../hdrs/funs.h ! fi if [ -d "../win32" ]; then cp ../hdrs/funs.h ../win32/funs.h --- 109,130 ---- $echo "You have too many switches defined!" fi ! mv -f ../hdrs/temp.h ../hdrs/switches.h ! mv -f ../src/temp.c ../src/switchinc.c $echo "Rebuilding command prototype file" $echo "/* AUTOGENERATED FILE. DO NOT EDIT */" >> ../hdrs/temp.h for c in `grep "^COMMAND *(" ../src/*.c | cut -f2 -d\( | cut -f1 -d\) | sort | uniq`; do $echo >>../hdrs/temp.h "COMMAND_PROTO($c);" done ! mv -f ../hdrs/temp.h ../hdrs/cmds.h $echo "Rebuilding function prototype file" $echo "/* AUTOGENERATED FILE. DO NOT EDIT */" >> ../hdrs/temp.h for c in `grep "^FUNCTION *(" ../src/*.c | cut -f2 -d\( | cut -f1 -d\) | sort | uniq`; do $echo >>../hdrs/temp.h "FUNCTION_PROTO($c);" done ! mv -f ../hdrs/temp.h ../hdrs/funs.h if [ -d "../win32" ]; then cp ../hdrs/funs.h ../win32/funs.h *** 1_7_6.36/src/wiz.c Tue, 26 Nov 2002 14:48:05 -0600 dunemush (pennmush/b/23_wiz.c 1.44.1.1.1.1.1.2.1.7.1.1.1.1.1.1.1.1.1.1.1.8.1.2.2.2 660) --- 1_7_6.56(w)/src/wiz.c Mon, 09 Dec 2002 14:04:32 -0600 dunemush (pennmush/b/23_wiz.c 1.44.1.1.1.1.1.2.1.7.1.1.1.1.1.1.1.1.1.1.1.8.1.2.2.2.1.2.1.1.1.1.1.1 660) *************** *** 576,582 **** char *s; ! for (s = command; *s && !isspace(*s); s++) ; if (!*s) return (0); *s++ = '\0'; --- 576,582 ---- char *s; ! for (s = command; *s && !isspace((unsigned char) *s); s++) ; if (!*s) return (0); *s++ = '\0'; *************** *** 1045,1051 **** return; } /* move past the not token if there is one */ ! for (s = power; *s && ((*s == NOT_TOKEN) || isspace(*s)); s++) ; if (*s == '\0') { notify(player, T("You must specify a power.")); --- 1045,1052 ---- return; } /* move past the not token if there is one */ ! for (s = power; *s && ((*s == NOT_TOKEN) || isspace((unsigned char) *s)); ! s++) ; if (*s == '\0') { notify(player, T("You must specify a power.")); *************** *** 1095,1119 **** /* First argument is a player, so we could have a quoted name */ if (PLAYER_NAME_SPACES && *arg1 == '\"') { ! for (; *arg1 && ((*arg1 == '\"') || isspace(*arg1)); arg1++) ; strcpy(tbuf, arg1); while (*arg2 && (*arg2 != '\"')) { while (*arg2 && (*arg2 != '\"')) arg2++; if (*arg2 == '\"') { *arg2++ = '\0'; ! while (*arg2 && isspace(*arg2)) arg2++; break; } } } else { strcpy(tbuf, arg1); ! while (*arg2 && !isspace(*arg2)) arg2++; if (*arg2) *arg2++ = '\0'; ! while (*arg2 && isspace(*arg2)) arg2++; } --- 1096,1121 ---- /* First argument is a player, so we could have a quoted name */ if (PLAYER_NAME_SPACES && *arg1 == '\"') { ! for (; *arg1 && ((*arg1 == '\"') || isspace((unsigned char) *arg1)); ! arg1++) ; strcpy(tbuf, arg1); while (*arg2 && (*arg2 != '\"')) { while (*arg2 && (*arg2 != '\"')) arg2++; if (*arg2 == '\"') { *arg2++ = '\0'; ! while (*arg2 && isspace((unsigned char) *arg2)) arg2++; break; } } } else { strcpy(tbuf, arg1); ! while (*arg2 && !isspace((unsigned char) *arg2)) arg2++; if (*arg2) *arg2++ = '\0'; ! while (*arg2 && isspace((unsigned char) *arg2)) arg2++; } *************** *** 1358,1363 **** --- 1360,1366 ---- restrict_type = TYPE_PLAYER; } else { notify(player, T("Unknown type.")); + return -1; } } else if (string_prefix("things", class) || string_prefix("objects", class)) { sclass = S_NAME; *** 1_7_6.36/src/help.c Fri, 05 Jul 2002 12:57:10 -0500 dunemush (pennmush/f/32_help.c 1.4.1.2.1.1.1.3.2.2.1.1.2.1.1.2.1.2.1.2.1.3.1.4 660) --- 1_7_6.56(w)/src/help.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/f/32_help.c 1.4.1.2.1.1.1.3.2.2.1.1.2.1.1.2.1.2.1.2.1.3.1.6 660) *************** *** 354,360 **** fclose(rfp); return; } ! if (isspace(line[0])) continue; if (line[0] != '&') { do_rawlog(LT_ERR, T("Malformed help file %s doesn't start with &"), --- 354,360 ---- fclose(rfp); return; } ! if (isspace((unsigned char) line[0])) continue; if (line[0] != '&') { do_rawlog(LT_ERR, T("Malformed help file %s doesn't start with &"), *** 1_7_6.36/src/strutil.c Sun, 10 Nov 2002 12:03:21 -0600 dunemush (pennmush/b/33_strutil.c 1.28.1.3.1.3.1.7.2.1.1.2.1.1.1.1.1.1.1.18 660) --- 1_7_6.56(w)/src/strutil.c Mon, 09 Dec 2002 14:04:29 -0600 dunemush (pennmush/b/33_strutil.c 1.28.1.3.1.3.1.7.2.1.1.2.1.1.1.1.1.1.1.21 660) *************** *** 128,136 **** if (string_prefix(src, sub)) return src; /* else scan to beginning of next word */ ! while (*src && (isalpha(*src) || isdigit(*src))) src++; ! while (*src && !isalpha(*src) && !isdigit(*src)) src++; } } --- 128,138 ---- if (string_prefix(src, sub)) return src; /* else scan to beginning of next word */ ! while (*src && (isalpha((unsigned char) *src) ! || isdigit((unsigned char) *src))) src++; ! while (*src && !isalpha((unsigned char) *src) ! && !isdigit((unsigned char) *src)) src++; } } *************** *** 687,693 **** */ char *c = (char *) s; ! while (c && *c && isspace(*c)) c++; return c; } --- 689,695 ---- */ char *c = (char *) s; ! while (c && *c && isspace((unsigned char) *c)) c++; return c; } *** 1_7_6.36/src/set.c Tue, 12 Nov 2002 09:41:55 -0600 dunemush (pennmush/b/38_set.c 1.26.1.5.1.1.2.1.1.1.1.1.1.9 660) --- 1_7_6.56(w)/src/set.c Mon, 09 Dec 2002 14:04:29 -0600 dunemush (pennmush/b/38_set.c 1.26.1.5.1.1.2.1.1.1.1.1.1.11 660) *************** *** 81,98 **** password++; if (*password == '\"') { *password++ = '\0'; ! while (*password && isspace(*password)) password++; break; } } } else { password = newname; ! while (*password && !isspace(*password)) password++; if (*password) { *password++ = '\0'; ! while (*password && isspace(*password)) password++; } } --- 81,98 ---- password++; if (*password == '\"') { *password++ = '\0'; ! while (*password && isspace((unsigned char) *password)) password++; break; } } } else { password = newname; ! while (*password && !isspace((unsigned char) *password)) password++; if (*password) { *password++ = '\0'; ! while (*password && isspace((unsigned char) *password)) password++; } } *************** *** 100,112 **** /* split off password */ for (password = newname + strlen(newname) - 1; ! *password && !isspace(*password); password--) ; ! for (; *password && isspace(*password); password--) ; /* eat whitespace */ if (*password) { *++password = '\0'; /* terminate name */ password++; ! while (*password && isspace(*password)) password++; } } --- 100,112 ---- /* split off password */ for (password = newname + strlen(newname) - 1; ! *password && !isspace((unsigned char) *password); password--) ; ! for (; *password && isspace((unsigned char) *password); password--) ; /* eat whitespace */ if (*password) { *++password = '\0'; /* terminate name */ password++; ! while (*password && isspace((unsigned char) *password)) password++; } } *************** *** 514,520 **** return; } /* move past NOT token if there is one */ ! for (p = flag; *p && ((*p == NOT_TOKEN) || isspace(*p)); p++) ; if ((af.f = string_to_atrflag(player, p)) < 0) { notify(player, T("Unrecognized attribute flag.")); --- 514,521 ---- return; } /* move past NOT token if there is one */ ! for (p = flag; *p && ((*p == NOT_TOKEN) || isspace((unsigned char) *p)); ! p++) ; if ((af.f = string_to_atrflag(player, p)) < 0) { notify(player, T("Unrecognized attribute flag.")); *************** *** 563,569 **** /* we haven't set an attribute, so we must be setting a flag */ /* move p past NOT_TOKEN if present */ ! for (p = (char *) flag; *p && (*p == NOT_TOKEN || isspace(*p)); p++) ; /* identify flag */ if (*p == '\0') { --- 564,571 ---- /* we haven't set an attribute, so we must be setting a flag */ /* move p past NOT_TOKEN if present */ ! for (p = (char *) flag; ! *p && (*p == NOT_TOKEN || isspace((unsigned char) *p)); p++) ; /* identify flag */ if (*p == '\0') { *** 1_7_6.36/src/rob.c Fri, 05 Jul 2002 12:57:10 -0500 dunemush (pennmush/b/42_rob.c 1.18.1.2.1.3.1.3.1.4 660) --- 1_7_6.56(w)/src/rob.c Mon, 09 Dec 2002 14:04:29 -0600 dunemush (pennmush/b/42_rob.c 1.18.1.2.1.3.1.3.1.6 660) *************** *** 142,148 **** } /* make sure amount is all digits */ ! for (s = amnt; *s && ((isdigit(*s)) || (*s == '-')); s++) ; /* must be giving object */ if (*s) { dbref thing; --- 142,148 ---- } /* make sure amount is all digits */ ! for (s = amnt; *s && ((isdigit((unsigned char) *s)) || (*s == '-')); s++) ; /* must be giving object */ if (*s) { dbref thing; *** 1_7_6.36/src/predicat.c Sat, 09 Nov 2002 18:52:33 -0600 dunemush (pennmush/b/44_predicat.c 1.1.1.34.1.1.1.3.1.4.2.7 660) --- 1_7_6.56(w)/src/predicat.c Mon, 09 Dec 2002 14:04:29 -0600 dunemush (pennmush/b/44_predicat.c 1.1.1.34.1.1.1.3.1.4.2.9 660) *************** *** 574,585 **** return 0; /* No leading spaces */ ! if (isspace(*name)) return 0; /* only printable characters */ for (p = name; p && *p; p++) { ! if (!isprint(*p)) return 0; if (ONLY_ASCII_NAMES && *p > 127) return 0; --- 574,585 ---- return 0; /* No leading spaces */ ! if (isspace((unsigned char) *name)) return 0; /* only printable characters */ for (p = name; p && *p; p++) { ! if (!isprint((unsigned char) *p)) return 0; if (ONLY_ASCII_NAMES && *p > 127) return 0; *************** *** 589,595 **** /* No trailing spaces */ p--; ! if (isspace(*p)) return 0; /* Not too long */ --- 589,595 ---- /* No trailing spaces */ p--; ! if (isspace((unsigned char) *p)) return 0; /* Not too long */ *************** *** 621,627 **** /* Make sure that the name contains legal characters only */ for (scan = (unsigned char *) name; scan && *scan; scan++) { ! if (isalnum(*scan)) continue; if (!strchr(good, *scan)) return 0; --- 621,627 ---- /* Make sure that the name contains legal characters only */ for (scan = (unsigned char *) name; scan && *scan; scan++) { ! if (isalnum((unsigned char) *scan)) continue; if (!strchr(good, *scan)) return 0; *************** *** 650,666 **** } int ! ok_command_name(name) ! const char *name; { /* is name ok for a command or function? * It must begin with an uppercase alpha, and contain only * uppercase alpha, numbers, or underscore thereafter. */ ! const char *p; ! if (!isupper(*name)) return 0; ! for (p = name; p && *p; p++) { if (!(isupper(*p) || isdigit(*p) || (*p == '_'))) return 0; } --- 650,665 ---- } int ! ok_command_name(const char *name) { /* is name ok for a command or function? * It must begin with an uppercase alpha, and contain only * uppercase alpha, numbers, or underscore thereafter. */ ! const unsigned char *p; ! if (!isupper((unsigned char) *name)) return 0; ! for (p = (unsigned char *) name; p && *p; p++) { if (!(isupper(*p) || isdigit(*p) || (*p == '_'))) return 0; } *************** *** 768,774 **** /* skip over the 's' and whitespace */ do { obj++; ! } while (isspace(*obj)); /* we already have a terminating null, so we're okay to just do matches */ loc = match_result(player, box, NOTYPE, MAT_NEIGHBOR | MAT_POSSESSION); --- 767,773 ---- /* skip over the 's' and whitespace */ do { obj++; ! } while (isspace((unsigned char) *obj)); /* we already have a terminating null, so we're okay to just do matches */ loc = match_result(player, box, NOTYPE, MAT_NEIGHBOR | MAT_POSSESSION); *** 1_7_6.36/src/parse.c Sun, 10 Nov 2002 08:51:00 -0600 dunemush (pennmush/b/48_parse.c 1.23.1.10.1.2.1.1.1.1.1.2.1.2.1.5 660) --- 1_7_6.56(w)/src/parse.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/b/48_parse.c 1.23.1.10.1.2.1.1.1.1.1.2.1.2.1.7 660) *************** *** 103,109 **** if (!str || (*str != NUMBER_TOKEN) || !*(str + 1)) return NOTHING; ! for (p = str + 1; isdigit(*p); p++) { } if (*p) return NOTHING; --- 103,109 ---- if (!str || (*str != NUMBER_TOKEN) || !*(str + 1)) return NOTHING; ! for (p = str + 1; isdigit((unsigned char) *p); p++) { } if (*p) return NOTHING; *************** *** 157,163 **** if (*(str + 1) == '-') { str++; } ! for (str++; isdigit(*str); str++) { } return !*str; } --- 157,163 ---- if (*(str + 1) == '-') { str++; } ! for (str++; isdigit((unsigned char) *str); str++) { } return !*str; } *************** *** 173,179 **** return 1; if (!str) return 0; ! while (isspace(*str)) str++; if (*str == '\0') return NULL_EQ_ZERO; --- 173,179 ---- return 1; if (!str) return 0; ! while (isspace((unsigned char) *str)) str++; if (*str == '\0') return NULL_EQ_ZERO; *************** *** 196,206 **** if (!str) return 0; /* strtoul() accepts negative numbers, so we still have to do this check */ ! while (isspace(*str)) str++; if (*str == '\0') return NULL_EQ_ZERO; ! if (!(isdigit(*str) || *str == '+')) return 0; errno = 0; strtoul(str, &end, 10); --- 196,206 ---- if (!str) return 0; /* strtoul() accepts negative numbers, so we still have to do this check */ ! while (isspace((unsigned char) *str)) str++; if (*str == '\0') return NULL_EQ_ZERO; ! if (!(isdigit((unsigned char) *str) || *str == '+')) return 0; errno = 0; strtoul(str, &end, 10); *************** *** 246,252 **** /* If we're emulating Tiny, anything is a number */ if (TINY_MATH) return 1; ! while (isspace(*str)) str++; if (*str == '\0') return NULL_EQ_ZERO; --- 246,252 ---- /* If we're emulating Tiny, anything is a number */ if (TINY_MATH) return 1; ! while (isspace((unsigned char) *str)) str++; if (*str == '\0') return NULL_EQ_ZERO; *************** *** 465,474 **** (*str)++; /* Check the first two characters after the $ for a number */ ! if (isdigit(**str)) { p = **str - '0'; (*str)++; ! if (isdigit(**str)) { p *= 10; p += **str - '0'; (*str)++; --- 465,474 ---- (*str)++; /* Check the first two characters after the $ for a number */ ! if (isdigit((unsigned char) **str)) { p = **str - '0'; (*str)++; ! if (isdigit((unsigned char) **str)) { p *= 10; p += **str - '0'; (*str)++; *************** *** 645,651 **** safe_chr(savec, buff, bp); } ! if (isupper(savec)) *savepos = UPCASE(*savepos); } break; --- 645,651 ---- safe_chr(savec, buff, bp); } ! if (isupper((unsigned char) savec)) *savepos = UPCASE(*savepos); } break; *** 1_7_6.36/src/match.c Mon, 10 Jun 2002 23:51:30 -0500 dunemush (pennmush/c/2_match.c 1.24.1.1.1.2 660) --- 1_7_6.56(w)/src/match.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/2_match.c 1.24.1.1.1.4 660) *************** *** 330,336 **** if (*match_name == LOOKUP_TOKEN) { ! for (p = match_name + 1; isspace(*p); p++) ; if ((match = lookup_player(p)) != NOTHING) { return match; } else { --- 330,336 ---- if (*match_name == LOOKUP_TOKEN) { ! for (p = match_name + 1; isspace((unsigned char) *p); p++) ; if ((match = lookup_player(p)) != NOTHING) { return match; } else { *************** *** 470,476 **** /* did we get it? */ if (*p == '\0') { /* make sure there's nothing afterwards */ ! while (isspace(*match)) match++; if (*match == '\0' || *match == EXIT_DELIMITER) { /* we got it */ --- 470,476 ---- /* did we get it? */ if (*p == '\0') { /* make sure there's nothing afterwards */ ! while (isspace((unsigned char) *match)) match++; if (*match == '\0' || *match == EXIT_DELIMITER) { /* we got it */ *************** *** 482,488 **** } /* we didn't get it, find next match */ while (*match && *match++ != EXIT_DELIMITER) ; ! while (isspace(*match)) match++; } } --- 482,488 ---- } /* we didn't get it, find next match */ while (*match && *match++ != EXIT_DELIMITER) ; ! while (isspace((unsigned char) *match)) match++; } } *** 1_7_6.36/src/malias.c Sat, 09 Nov 2002 19:47:06 -0600 dunemush (pennmush/c/3_malias.c 1.34 660) --- 1_7_6.56(w)/src/malias.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/3_malias.c 1.36.1.1 660) *************** *** 142,148 **** good = "`$_-.'"; /* Make sure that the name contains legal characters only */ for (scan = alias + 1; scan && *scan; scan++) { ! if (isalpha(*scan) || isdigit(*scan)) continue; if (!strchr(good, *scan)) { notify(player, T("MAIL: Invalid character in mail alias.")); --- 142,148 ---- good = "`$_-.'"; /* Make sure that the name contains legal characters only */ for (scan = alias + 1; scan && *scan; scan++) { ! if (isalpha((unsigned char) *scan) || isdigit((unsigned char) *scan)) continue; if (!strchr(good, *scan)) { notify(player, T("MAIL: Invalid character in mail alias.")); *************** *** 932,945 **** } if (!m->mflags) ! privs[3] = 'E'; else { if (m->mflags & ALIAS_MEMBERS) ! privs[3] = 'M'; if (m->mflags & ALIAS_ADMIN) ! privs[4] = 'A'; ! if (!strncmp(privs + 3, "--", 2)) ! privs[4] = 'O'; } return privs; --- 932,945 ---- } if (!m->mflags) ! privs[4] = 'E'; else { if (m->mflags & ALIAS_MEMBERS) ! privs[4] = 'M'; if (m->mflags & ALIAS_ADMIN) ! privs[5] = 'A'; ! if (!strncmp(privs + 4, "--", 2)) ! privs[5] = 'O'; } return privs; *** 1_7_6.36/src/log.c Wed, 28 Aug 2002 09:50:52 -0500 dunemush (pennmush/c/5_log.c 1.10.1.2.2.4.1.1 660) --- 1_7_6.56(w)/src/log.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/5_log.c 1.10.1.2.2.4.1.1.2.1 660) *************** *** 294,299 **** --- 294,300 ---- default: lname = "unspecified"; } + notify(player, T("Wrong password.")); do_log(LT_WIZ, player, NOTHING, T("Invalid attempt to wipe the %s log, password %s"), lname, str); return; *** 1_7_6.36/src/info_slave.c Fri, 04 Jan 2002 15:23:43 -0600 dunemush (pennmush/c/7_info_slave 1.9.1.4 660) --- 1_7_6.56(w)/src/info_slave.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/7_info_slave 1.9.1.4.1.1 660) *************** *** 97,108 **** int len, size; IDENT *ident_result; char host[NI_MAXHOST]; ! int use_ident, timeout; socklen_t llen, rlen; struct iovec dat[3]; if (argc < 2) { ! fprintf(stderr, "info_slave needs port number!\n"); exit(1); } port = atoi(argv[1]); --- 97,108 ---- int len, size; IDENT *ident_result; char host[NI_MAXHOST]; ! int use_ident, use_dns, timeout; socklen_t llen, rlen; struct iovec dat[3]; if (argc < 2) { ! fprintf(stderr, "info_slave needs a port number!\n"); exit(1); } port = atoi(argv[1]); *************** *** 114,119 **** --- 114,126 ---- use_ident = atoi(argv[2]); } else use_ident = 5; + + if (argc >= 4) { + /* The third argument is 1 to do DNS lookups, 0 to not. */ + use_dns = atoi(argv[3]); + } else + use_dns = 1; + #ifdef HAS_SOCKETPAIR mush = port; /* We inherit open file descriptions and sockets from parent */ #else *************** *** 182,193 **** if (ident_result) ident_free(ident_result); } ! if (getnameinfo(&remote.addr, rlen, host, sizeof host, NULL, 0, ! NI_NUMERICSERV) != 0) { ! safe_str("An error occured", buf, &bp); ! } else { safe_str(host, buf, &bp); - } *bp = '\0'; size = strlen(buf); dat[0].iov_base = (char *) &fd; --- 189,203 ---- if (ident_result) ident_free(ident_result); } ! if (use_dns) { ! if (getnameinfo(&remote.addr, rlen, host, sizeof host, NULL, 0, ! NI_NUMERICSERV) != 0) { ! safe_str("An error occured", buf, &bp); ! } else { ! safe_str(host, buf, &bp); ! } ! } else safe_str(host, buf, &bp); *bp = '\0'; size = strlen(buf); dat[0].iov_base = (char *) &fd; *** 1_7_6.36/src/ident.c Mon, 19 Aug 2002 21:42:39 -0500 dunemush (pennmush/c/8_ident.c 1.19.1.4.1.9 660) --- 1_7_6.56(w)/src/ident.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/8_ident.c 1.19.1.4.1.11 660) *************** *** 364,370 **** /* ** Skip leading spaces */ ! while (isspace(*bp)) bp++; /* --- 364,370 ---- /* ** Skip leading spaces */ ! while (isspace((unsigned char) *bp)) bp++; /* *************** *** 380,386 **** */ /* Remove trailing spaces */ *dc = *bp; ! for (dc = bp - 1; dc > cp && isspace(*dc); dc--) ; *++dc = '\0'; bp++; --- 380,386 ---- */ /* Remove trailing spaces */ *dc = *bp; ! for (dc = bp - 1; dc > cp && isspace((unsigned char) *dc); dc--) ; *++dc = '\0'; bp++; *** 1_7_6.36/src/game.c Sun, 10 Nov 2002 14:27:19 -0600 dunemush (pennmush/c/10_game.c 1.50.1.8.1.1.1.1.2.1.1.1.2.1.1.4.1.1.1.1.1.1.1.1.1.1.2.1.1.2.1.1.1.1.1.1.1.2.1.1.1.2.1.1.1.1.1.1.1.1.1.5.1.3.1.2 660) --- 1_7_6.56(w)/src/game.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/10_game.c 1.50.1.8.1.1.1.1.2.1.1.1.2.1.1.4.1.1.1.1.1.1.1.1.1.1.2.1.1.2.1.1.1.1.1.1.1.2.1.1.1.2.1.1.1.1.1.1.1.1.1.5.1.3.1.2.1.2 660) *************** *** 858,869 **** raw_notify(Owner(player), tprintf("#%d] %s", player, command)); /* eat leading whitespace */ ! while (*command && isspace(*command)) command++; /* eat trailing whitespace */ p = command + strlen(command) - 1; ! while (isspace(*p) && (p >= command)) p--; *++p = '\0'; --- 858,869 ---- raw_notify(Owner(player), tprintf("#%d] %s", player, command)); /* eat leading whitespace */ ! while (*command && isspace((unsigned char) *command)) command++; /* eat trailing whitespace */ p = command + strlen(command) - 1; ! while (isspace((unsigned char) *p) && (p >= command)) p--; *++p = '\0'; *************** *** 993,1001 **** #undef cmd_match int ! check_alias(command, list) ! const char *command; ! const char *list; { /* check if a string matches part of a semi-colon separated list */ const char *p; --- 993,999 ---- #undef cmd_match int ! check_alias(const char *command, const char *list) { /* check if a string matches part of a semi-colon separated list */ const char *p; *************** *** 1003,1016 **** for (p = command; (*p && DOWNCASE(*p) == DOWNCASE(*list) && *list != EXIT_DELIMITER); p++, list++) ; if (*p == '\0') { ! while (isspace(*list)) list++; if (*list == '\0' || *list == EXIT_DELIMITER) return 1; /* word matched */ } /* didn't match. check next word in list */ while (*list && *list++ != EXIT_DELIMITER) ; ! while (isspace(*list)) list++; } /* reached the end of the list without matching anything */ --- 1001,1014 ---- for (p = command; (*p && DOWNCASE(*p) == DOWNCASE(*list) && *list != EXIT_DELIMITER); p++, list++) ; if (*p == '\0') { ! while (isspace((unsigned char) *list)) list++; if (*list == '\0' || *list == EXIT_DELIMITER) return 1; /* word matched */ } /* didn't match. check next word in list */ while (*list && *list++ != EXIT_DELIMITER) ; ! while (isspace((unsigned char) *list)) list++; } /* reached the end of the list without matching anything */ *** 1_7_6.36/src/funtime.c Wed, 30 Oct 2002 21:55:20 -0600 dunemush (pennmush/c/12_funtime.c 1.11.1.12 660) --- 1_7_6.56(w)/src/funtime.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/12_funtime.c 1.11.1.14 660) *************** *** 288,294 **** /* get the day of month */ p = q; ! while (isspace(*p)) /* skip leading space */ p++; if (!(q = strchr(p, ' '))) return 0; --- 288,294 ---- /* get the day of month */ p = q; ! while (isspace((unsigned char) *p)) /* skip leading space */ p++; if (!(q = strchr(p, ' '))) return 0; *** 1_7_6.36/src/funstr.c Sun, 10 Nov 2002 14:27:19 -0600 dunemush (pennmush/c/13_funstr.c 1.28.1.1.1.2.1.4.1.6.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.3.1.5.1.3 660) --- 1_7_6.56(w)/src/funstr.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/13_funstr.c 1.28.1.1.1.2.1.4.1.6.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.3.1.5.1.3.1.2 660) *************** *** 74,80 **** return; } for (p = args[0]; *p; p++) { ! if (!isalpha((int) *p)) { safe_chr('0', buff, bp); return; } --- 74,80 ---- return; } for (p = args[0]; *p; p++) { ! if (!isalpha((unsigned char) *p)) { safe_chr('0', buff, bp); return; } *** 1_7_6.36/src/funmisc.c Wed, 30 Oct 2002 14:26:02 -0600 dunemush (pennmush/c/14_funmisc.c 1.30.1.1.1.9 660) --- 1_7_6.56(w)/src/funmisc.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/14_funmisc.c 1.30.1.1.1.12 660) *************** *** 57,62 **** --- 57,63 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_pemit_list(executor, args[0], args[1], 1); } *************** *** 67,72 **** --- 68,74 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_pemit_list(executor, args[0], args[1], 0); } *************** *** 77,82 **** --- 79,85 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_oemit_list(executor, args[0], args[1]); } *************** *** 87,92 **** --- 90,96 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_emit(executor, args[0]); } *************** *** 97,102 **** --- 101,107 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_remit(executor, args[0], args[1], 0); } *************** *** 107,112 **** --- 112,118 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_lemit(executor, args[0], 0); } *************** *** 117,122 **** --- 123,129 ---- safe_str(T(e_perm), buff, bp); return; } + orator = executor; do_zemit(executor, args[0], args[1]); } *************** *** 132,137 **** --- 139,145 ---- } if (nargs == 3 && parse_boolean(args[2])) noisy = 1; + orator = executor; do_cemit(executor, args[0], args[1], noisy); } #endif *************** *** 392,398 **** p++; /* Convert letters to soundex values, squash duplicates */ while (*q) { ! if (!isalpha(*q) || !isascii(*q)) { q++; continue; } --- 400,406 ---- p++; /* Convert letters to soundex values, squash duplicates */ while (*q) { ! if (!isalpha((unsigned char) *q) || !isascii((unsigned char) *q)) { q++; continue; } *************** *** 431,439 **** * 5. Truncate to 4 characters or pad with 0's. * It's actually a bit messier than that to make it faster. */ ! if (!args[0] || !*args[0] || !isalpha(*args[0]) || strchr(args[0], ' ')) { ! safe_str(T("#-1 FUNCTION (SOUNDEX) REQUIRES A SINGLE WORD ARGUMENT"), ! buff, bp); return; } safe_str(soundex(args[0]), buff, bp); --- 439,448 ---- * 5. Truncate to 4 characters or pad with 0's. * It's actually a bit messier than that to make it faster. */ ! if (!args[0] || !*args[0] || !isalpha((unsigned char) *args[0]) ! || strchr(args[0], ' ')) { ! safe_str(T("#-1 FUNCTION (SOUNDEX) REQUIRES A SINGLE WORD ARGUMENT"), buff, ! bp); return; } safe_str(soundex(args[0]), buff, bp); *** 1_7_6.36/src/funmath.c Sat, 09 Nov 2002 18:52:33 -0600 dunemush (pennmush/c/15_funmath.c 1.39.1.1.1.1.1.1.1.8 660) --- 1_7_6.56(w)/src/funmath.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/c/15_funmath.c 1.39.1.1.1.1.1.1.1.10 660) *************** *** 227,233 **** return; } p = args[0] + arglens[0] - 1; ! if (!isdigit(*p)) { if (NULL_EQ_ZERO) { safe_str(args[0], buff, bp); safe_str("1", buff, bp); --- 227,233 ---- return; } p = args[0] + arglens[0] - 1; ! if (!isdigit((unsigned char) *p)) { if (NULL_EQ_ZERO) { safe_str(args[0], buff, bp); safe_str("1", buff, bp); *************** *** 235,241 **** safe_str(T("#-1 ARGUMENT MUST END IN AN INTEGER"), buff, bp); return; } ! while ((isdigit(*p) || (*p == '-')) && p != args[0]) { if (*p == '-') { p--; break; --- 235,241 ---- safe_str(T("#-1 ARGUMENT MUST END IN AN INTEGER"), buff, bp); return; } ! while ((isdigit((unsigned char) *p) || (*p == '-')) && p != args[0]) { if (*p == '-') { p--; break; *************** *** 269,275 **** return; } p = args[0] + arglens[0] - 1; ! if (!isdigit(*p)) { if (NULL_EQ_ZERO) { safe_str(args[0], buff, bp); safe_str("-1", buff, bp); --- 269,275 ---- return; } p = args[0] + arglens[0] - 1; ! if (!isdigit((unsigned char) *p)) { if (NULL_EQ_ZERO) { safe_str(args[0], buff, bp); safe_str("-1", buff, bp); *************** *** 277,283 **** safe_str(T("#-1 ARGUMENT MUST END IN AN INTEGER"), buff, bp); return; } ! while ((isdigit(*p) || (*p == '-')) && p != args[0]) { if (*p == '-') { p--; break; --- 277,283 ---- safe_str(T("#-1 ARGUMENT MUST END IN AN INTEGER"), buff, bp); return; } ! while ((isdigit((unsigned char) *p) || (*p == '-')) && p != args[0]) { if (*p == '-') { p--; break; *************** *** 1230,1236 **** dot = 1; /* allow only 1 dot in a number */ *pnumber = '\0'; /* devide the string */ pnum2 = pnumber + 1; ! } else if (!isdigit(*pnumber)) { safe_str(T(e_num), buff, bp); return; } --- 1230,1236 ---- dot = 1; /* allow only 1 dot in a number */ *pnumber = '\0'; /* devide the string */ pnum2 = pnumber + 1; ! } else if (!isdigit((unsigned char) *pnumber)) { safe_str(T(e_num), buff, bp); return; } *** 1_7_6.36/src/function.c Wed, 30 Oct 2002 14:26:02 -0600 dunemush (pennmush/c/18_function.c 1.29.1.14.1.3.1.6.1.1.1.1.1.14 660) --- 1_7_6.56(w)/src/function.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/18_function.c 1.29.1.14.1.3.1.6.1.1.1.1.1.14.1.2 660) *************** *** 653,660 **** */ char * ! strip_braces(str) ! char const *str; { /* this is a hack which just strips a level of braces. It malloc()s memory * which must be free()d later. --- 653,659 ---- */ char * ! strip_braces(const char *str) { /* this is a hack which just strips a level of braces. It malloc()s memory * which must be free()d later. *************** *** 666,672 **** buff = (char *) mush_malloc(BUFFER_LEN, "strip_braces.buff"); bufc = buff; ! while (isspace(*str)) /* eat spaces at the beginning */ str++; switch (*str) { --- 665,671 ---- buff = (char *) mush_malloc(BUFFER_LEN, "strip_braces.buff"); bufc = buff; ! while (isspace((unsigned char) *str)) /* eat spaces at the beginning */ str++; switch (*str) { *** 1_7_6.36/src/flags.c Wed, 20 Nov 2002 21:50:51 -0600 dunemush (pennmush/c/20_flags.c 1.1.1.1.1.1.1.1.1.1.1.1.1.6.1.2.1.1.1.1.1.2.2.2.2.1.2.1.1.3.1.2.1.1.1.1.1.1.1.1.1.3.1.9.1.2.2.1 660) --- 1_7_6.56(w)/src/flags.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/20_flags.c 1.1.1.1.1.1.1.1.1.1.1.1.1.6.1.2.1.1.1.1.1.2.2.2.2.1.2.1.1.3.1.2.1.1.1.1.1.1.1.1.1.3.1.9.1.2.2.1.1.2 660) *************** *** 402,408 **** toggle_need &= ~f->flag; *p++ = f->letter; } else if ((f->type == NOTYPE) && (flag_need & f->flag) && ! !(f->perms & F_INTERNAL) && Can_See_Flag(player, thing, f)) { flag_need &= ~f->flag; *p++ = f->letter; } --- 402,408 ---- toggle_need &= ~f->flag; *p++ = f->letter; } else if ((f->type == NOTYPE) && (flag_need & f->flag) && ! Can_See_Flag(player, thing, f)) { flag_need &= ~f->flag; *p++ = f->letter; } *** 1_7_6.36/src/extmail.c Sat, 09 Nov 2002 19:47:06 -0600 dunemush (pennmush/c/22_extmail.c 1.44.1.7.1.5.1.7 660) --- 1_7_6.56(w)/src/extmail.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/22_extmail.c 1.44.1.7.1.5.1.9 660) *************** *** 177,183 **** *p = '\0'; break; } ! if (!isprint(*p)) { *p = ' '; } } --- 177,183 ---- *p = '\0'; break; } ! if (!isprint((unsigned char) *p)) { *p = ' '; } } *************** *** 219,225 **** return; } for (p = newname; p && *p; p++) { ! if (!isdigit(*p) && !isalpha(*p)) { notify(player, T("MAIL: Illegal folder name")); return; } --- 219,225 ---- return; } for (p = newname; p && *p; p++) { ! if (!isdigit((unsigned char) *p) && !isalpha((unsigned char) *p)) { notify(player, T("MAIL: Illegal folder name")); return; } *************** *** 1336,1342 **** do_mail_send(sender, arg1, arg2, 0, 0, 0); } else { /* Must be reading or listing mail - no arg2 */ ! if (isdigit(*arg1) && !strchr(arg1, '-')) do_mail_read(player, arg1); else do_mail_list(player, arg1); --- 1336,1342 ---- do_mail_send(sender, arg1, arg2, 0, 0, 0); } else { /* Must be reading or listing mail - no arg2 */ ! if (isdigit((unsigned char) *arg1) && !strchr(arg1, '-')) do_mail_read(player, arg1); else do_mail_list(player, arg1); *************** *** 2006,2012 **** return -1; res += 2 + strlen(name); p = res; ! while (isdigit(*p)) p++; *p = '\0'; return atoi(res); --- 2006,2012 ---- return -1; res += 2 + strlen(name); p = res; ! while (isdigit((unsigned char) *p)) p++; *p = '\0'; return atoi(res); *************** *** 2081,2087 **** if (old && *old) { strcpy(tbuf, str); r = old; ! while (!isspace(*r)) r++; *r = '\0'; res = replace_string(old, new, tbuf); /* mallocs mem! */ --- 2081,2087 ---- if (old && *old) { strcpy(tbuf, str); r = old; ! while (!isspace((unsigned char) *r)) r++; *r = '\0'; res = replace_string(old, new, tbuf); /* mallocs mem! */ *************** *** 2147,2153 **** * for now. Later, this will be where named folders are handled */ if (!folder_string || !*folder_string) return -1; ! if (isdigit(*folder_string)) { fnum = atoi(folder_string); if ((fnum < 0) || (fnum > MAX_FOLDERS)) return -1; --- 2147,2153 ---- * for now. Later, this will be where named folders are handled */ if (!folder_string || !*folder_string) return -1; ! if (isdigit((unsigned char) *folder_string)) { fnum = atoi(folder_string); if ((fnum < 0) || (fnum > MAX_FOLDERS)) return -1; *************** *** 2235,2247 **** /* Don't mess with msglist itself */ strncpy(tbuf1, msglist, BUFFER_LEN - 1); p = tbuf1; ! while (p && *p && isspace(*p)) p++; if (!p || !*p) { ms->flags |= M_FOLDER; return 1; /* all messages in current folder */ } ! if (isdigit(*p) || *p == '-') { if (!parse_message_spec(player, p, &ms->low, &ms->high, &folder)) { notify(player, T("MAIL: Invalid message specification")); return 0; --- 2235,2247 ---- /* Don't mess with msglist itself */ strncpy(tbuf1, msglist, BUFFER_LEN - 1); p = tbuf1; ! while (p && *p && isspace((unsigned char) *p)) p++; if (!p || !*p) { ms->flags |= M_FOLDER; return 1; /* all messages in current folder */ } ! if (isdigit((unsigned char) *p) || *p == '-') { if (!parse_message_spec(player, p, &ms->low, &ms->high, &folder)) { notify(player, T("MAIL: Invalid message specification")); return 0; *** 1_7_6.36/src/extchat.c Wed, 20 Nov 2002 21:50:51 -0600 dunemush (pennmush/c/23_extchat.c 1.1.1.1.1.1.1.1.1.2.1.1.1.3.1.1.1.5.1.1.1.1.1.5.1.2.1.3.1.3.1.1.1.4.1.2.1.6.1.2.1.1.2.4.2.9.1.2.1.2.1.3.1.2.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.2.1.1.2.1 660) --- 1_7_6.56(w)/src/extchat.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/23_extchat.c 1.1.1.1.1.1.1.1.1.2.1.1.1.3.1.1.1.5.1.1.1.1.1.5.1.2.1.3.1.3.1.1.1.4.1.2.1.6.1.2.1.1.2.4.2.9.1.2.1.2.1.3.1.2.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.2.1.1.2.1.1.2 660) *************** *** 1089,1100 **** s = tbuf1; arg1 = s; ! while (*s && !isspace(*s)) s++; if (*s) { *s++ = '\0'; ! while (*s && isspace(*s)) s++; } arg2 = s; --- 1089,1100 ---- s = tbuf1; arg1 = s; ! while (*s && !isspace((unsigned char) *s)) s++; if (*s) { *s++ = '\0'; ! while (*s && isspace((unsigned char) *s)) s++; } arg2 = s; *************** *** 1595,1601 **** } /* Stomp newlines and other weird whitespace */ for (scan = title; *scan; scan++) { ! if ((isspace(*scan) && (*scan != ' ')) || (*scan == BEEP_CHAR)) { notify(player, T("Invalid character in title.")); return; } --- 1595,1602 ---- } /* Stomp newlines and other weird whitespace */ for (scan = title; *scan; scan++) { ! if ((isspace((unsigned char) *scan) && (*scan != ' ')) ! || (*scan == BEEP_CHAR)) { notify(player, T("Invalid character in title.")); return; } *** 1_7_6.36/src/destroy.c Wed, 20 Nov 2002 09:43:49 -0600 dunemush (pennmush/c/24_destroy.c 1.24.2.2.1.3.1.1.1.1.1.1.1.4 660) --- 1_7_6.56(w)/src/destroy.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/24_destroy.c 1.24.2.2.1.3.1.1.1.1.1.1.1.4.1.1 660) *************** *** 327,332 **** --- 327,336 ---- return; } /* Present informative messages. */ + if (!REALLY_SAFE && Safe(thing)) + notify(player, + T + ("Warning: Target is set SAFE, but scheduling for destruction anyway.")); switch (Typeof(thing)) { case TYPE_ROOM: /* wait until dbck */ *** 1_7_6.36/src/db.c Fri, 05 Jul 2002 12:57:10 -0500 dunemush (pennmush/c/25_db.c 1.26.1.1.1.1.1.4 660) --- 1_7_6.56(w)/src/db.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/25_db.c 1.26.1.1.1.1.1.6 660) *************** *** 672,678 **** /* smash unprintable characters in the name, replace with ! */ strcpy(name, AL_NAME(list)); for (p = name; *p; p++) { ! if (!isprint(*p) || isspace(*p)) { *p = '!'; fixmemdb = err = 1; } --- 672,678 ---- /* smash unprintable characters in the name, replace with ! */ strcpy(name, AL_NAME(list)); for (p = name; *p; p++) { ! if (!isprint((unsigned char) *p) || isspace((unsigned char) *p)) { *p = '!'; fixmemdb = err = 1; } *************** *** 713,720 **** /* get rid of unprintables and hard newlines */ lastp = '\0'; for (p = tbuf1; *p; p++) { ! if (!isprint(*p)) { ! if (!isspace(*p)) { *p = '!'; err = 1; } --- 713,720 ---- /* get rid of unprintables and hard newlines */ lastp = '\0'; for (p = tbuf1; *p; p++) { ! if (!isprint((unsigned char) *p)) { ! if (!isspace((unsigned char) *p)) { *p = '!'; err = 1; } *** 1_7_6.36/src/conf.c Sun, 10 Nov 2002 14:27:19 -0600 dunemush (pennmush/c/31_conf.c 1.41.2.3.1.3.1.2.1.13 660) --- 1_7_6.56(w)/src/conf.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/31_conf.c 1.41.2.3.1.3.1.2.1.15 660) *************** *** 634,640 **** /* Was this "restrict_command "? If so, do it */ if (!strcasecmp(opt, "restrict_command")) { ! for (p = val; *p && !isspace(*p); p++) ; if (*p) { *p++ = '\0'; if (!restrict_command(val, p)) { --- 634,640 ---- /* Was this "restrict_command "? If so, do it */ if (!strcasecmp(opt, "restrict_command")) { ! for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; if (!restrict_command(val, p)) { *************** *** 655,661 **** } return 1; } else if (!strcasecmp(opt, "command_alias")) { ! for (p = val; *p && !isspace(*p); p++) ; if (*p) { *p++ = '\0'; if (!alias_command(val, p)) { --- 655,661 ---- } return 1; } else if (!strcasecmp(opt, "command_alias")) { ! for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; if (!alias_command(val, p)) { *************** *** 673,679 **** } return 1; } else if (!strcasecmp(opt, "attribute_alias")) { ! for (p = val; *p && !isspace(*p); p++) ; if (*p) { *p++ = '\0'; if (!alias_attribute(val, p)) { --- 673,679 ---- } return 1; } else if (!strcasecmp(opt, "attribute_alias")) { ! for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; if (!alias_attribute(val, p)) { *************** *** 691,697 **** } return 1; } else if (!strcasecmp(opt, "function_alias")) { ! for (p = val; *p && !isspace(*p); p++) ; if (*p) { *p++ = '\0'; if (!alias_function(val, p)) { --- 691,697 ---- } return 1; } else if (!strcasecmp(opt, "function_alias")) { ! for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; if (!alias_function(val, p)) { *************** *** 709,715 **** } return 1; } else if (!strcasecmp(opt, "restrict_function")) { ! for (p = val; *p && !isspace(*p); p++) ; if (*p) { *p++ = '\0'; if (!restrict_function(val, p)) { --- 709,715 ---- } return 1; } else if (!strcasecmp(opt, "restrict_function")) { ! for (p = val; *p && !isspace((unsigned char) *p); p++) ; if (*p) { *p++ = '\0'; if (!restrict_function(val, p)) { *************** *** 747,753 **** return 0; } comm = val; ! for (file = val; *file && !isspace(*file); file++) ; if (*file) { *file++ = '\0'; add_help_file(comm, file, admin); --- 747,753 ---- return 0; } comm = val; ! for (file = val; *file && !isspace((unsigned char) *file); file++) ; if (*file) { *file++ = '\0'; add_help_file(comm, file, admin); *************** *** 1000,1017 **** for (p = tbuf1; *p && (*p != '\n') && (*p != '\r'); p++) ; *p = '\0'; /* strip the end of line char(s) */ ! for (p = tbuf1; *p && isspace(*p); p++) /* strip spaces */ ; ! for (q = p; *q && !isspace(*q); q++) /* move over command */ ; if (*q) *q++ = '\0'; /* split off command */ ! for (; *q && isspace(*q); q++) /* skip spaces */ ; /* If the first character of the value is a #, and that is followed by a number, treat it as a dbref instead of a comment. */ ! if (*q == '#' && isdigit(*(q + 1))) { for (s = q + 1; *s && (*s != '#'); s++) /* look for a real comment */ ; } else { --- 1000,1017 ---- for (p = tbuf1; *p && (*p != '\n') && (*p != '\r'); p++) ; *p = '\0'; /* strip the end of line char(s) */ ! for (p = tbuf1; *p && isspace((unsigned char) *p); p++) /* strip spaces */ ; ! for (q = p; *q && !isspace((unsigned char) *q); q++) /* move over command */ ; if (*q) *q++ = '\0'; /* split off command */ ! for (; *q && isspace((unsigned char) *q); q++) /* skip spaces */ ; /* If the first character of the value is a #, and that is followed by a number, treat it as a dbref instead of a comment. */ ! if (*q == '#' && isdigit((unsigned char) *(q + 1))) { for (s = q + 1; *s && (*s != '#'); s++) /* look for a real comment */ ; } else { *************** *** 1020,1026 **** } if (*s) /* if found nuke it */ *s = '\0'; ! for (s = s - 1; (s >= q) && isspace(*s); s--) /* smash trailing stuff */ *s = '\0'; if (strlen(p) != 0) { /* skip blank lines */ --- 1020,1026 ---- } if (*s) /* if found nuke it */ *s = '\0'; ! for (s = s - 1; (s >= q) && isspace((unsigned char) *s); s--) /* smash trailing stuff */ *s = '\0'; if (strlen(p) != 0) { /* skip blank lines */ *** 1_7_6.36/src/bsd.c Sat, 23 Nov 2002 11:19:02 -0600 dunemush (pennmush/c/38_bsd.c 1.58.1.11.1.2.1.5.1.7.1.14.1.13.1.9.1.4.1.2.1.12.1.1.1.1.1.2.1.1.1.13.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.8.2.1.1.1 660) --- 1_7_6.56(w)/src/bsd.c Mon, 09 Dec 2002 14:04:27 -0600 dunemush (pennmush/c/38_bsd.c 1.58.1.11.1.2.1.5.1.7.1.14.1.13.1.9.1.4.1.2.1.12.1.1.1.1.1.2.1.1.1.13.1.1.1.1.1.1.1.1.1.1.1.3.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.3.1.8.2.1.1.1.1.1.1.1.1.2.1.1 660) *************** *** 1727,1733 **** while ((curr = split_token(&fwdstr, ' ')) != NULL) { if (is_dbref(curr)) { fwd = parse_dbref(curr); ! if (GoodObject(fwd) && !IsGarbage(fwd) && Can_Forward(target, fwd)) if (IsRoom(fwd)) { notify_anything(speaker, na_loc, &fwd, NULL, flags | NA_NORELAY, tbuf1); --- 1727,1733 ---- while ((curr = split_token(&fwdstr, ' ')) != NULL) { if (is_dbref(curr)) { fwd = parse_dbref(curr); ! if (GoodObject(fwd) && !IsGarbage(fwd) && Can_Forward(target, fwd)) { if (IsRoom(fwd)) { notify_anything(speaker, na_loc, &fwd, NULL, flags | NA_NORELAY, tbuf1); *************** *** 1735,1740 **** --- 1735,1741 ---- notify_anything(speaker, na_one, &fwd, NULL, flags | NA_NORELAY, tbuf1); } + } } } free((Malloc_t) orig); *************** *** 2237,2243 **** socket_ident = ident_id(newsock, &timeout); if (socket_ident) { /* Truncate at first non-printable character */ ! for (chp = socket_ident; *chp && isprint(*chp); chp++) ; *chp = '\0'; safe_str(socket_ident, tbuf1, &bp); safe_chr('@', tbuf1, &bp); --- 2238,2244 ---- socket_ident = ident_id(newsock, &timeout); if (socket_ident) { /* Truncate at first non-printable character */ ! for (chp = socket_ident; *chp && isprint((unsigned char) *chp); chp++) ; *chp = '\0'; safe_str(socket_ident, tbuf1, &bp); safe_chr('@', tbuf1, &bp); *************** *** 2756,2765 **** sprintf(num, "%d", socks[1]); #endif if (!USE_IDENT) ! execl("./info_slave", "./info_slave", num, "-1", (char *) NULL); else execl("./info_slave", "./info_slave", num, tprintf("%d", IDENT_TIMEOUT), ! (char *) NULL); perror("execing info slave"); exit(1); } --- 2757,2767 ---- sprintf(num, "%d", socks[1]); #endif if (!USE_IDENT) ! execl("./info_slave", "./info_slave", num, "-1", USE_DNS ? "1" : "0", ! (char *) NULL); else execl("./info_slave", "./info_slave", num, tprintf("%d", IDENT_TIMEOUT), ! USE_DNS ? "1" : "0", (char *) NULL); perror("execing info slave"); exit(1); } *************** *** 3696,3701 **** --- 3698,3705 ---- process_command(d->player, command, d->player, 1); send_suffix(d); + strcpy(ccom, ""); + cplr = NOTHING; } else { if (!check_connect(d, command)) return 0; *************** *** 3976,3998 **** } void ! parse_connect(msg, command, user, pass) ! const char *msg; ! char *command; ! char *user; ! char *pass; { ! char *p; while (*msg && isspace(*msg)) msg++; ! p = command; while (*msg && isprint(*msg) && !isspace(*msg)) *p++ = *msg++; *p = '\0'; while (*msg && isspace(*msg)) msg++; ! p = user; if (PLAYER_NAME_SPACES && *msg == '\"') { for (; *msg && ((*msg == '\"') || isspace(*msg)); msg++) ; --- 3980,3999 ---- } void ! parse_connect(const char *msg1, char *command, char *user, char *pass) { ! unsigned char *p; ! unsigned const char *msg = (unsigned const char *) msg1; while (*msg && isspace(*msg)) msg++; ! p = (unsigned char *) command; while (*msg && isprint(*msg) && !isspace(*msg)) *p++ = *msg++; *p = '\0'; while (*msg && isspace(*msg)) msg++; ! p = (unsigned char *) user; if (PLAYER_NAME_SPACES && *msg == '\"') { for (; *msg && ((*msg == '\"') || isspace(*msg)); msg++) ; *************** *** 4017,4023 **** *p = '\0'; while (*msg && isspace(*msg)) msg++; ! p = pass; while (*msg && isprint(*msg) && !isspace(*msg)) *p++ = *msg++; *p = '\0'; --- 4018,4024 ---- *p = '\0'; while (*msg && isspace(*msg)) msg++; ! p = (unsigned char *) pass; while (*msg && isprint(*msg) && !isspace(*msg)) *p++ = *msg++; *p = '\0'; *************** *** 5461,5467 **** exit(0); } /* Write out the reboot db flags here */ ! fprintf(f, "V%d\n", flags); putref(f, sock); putref(f, maxd); --- 5462,5468 ---- exit(0); } /* Write out the reboot db flags here */ ! fprintf(f, "V%ld\n", flags); putref(f, sock); putref(f, maxd); *************** *** 5630,5636 **** struct hostname_info *hi; char *socket_ident; char *chp; - /* int i; */ BOOL b; char tbuf1[BUFFER_LEN]; --- 5631,5636 ---- *************** *** 5666,5672 **** socket_ident = ident_id(socketClient, &timeout); if (socket_ident) { /* Truncate at first non-printable character */ ! for (chp = socket_ident; *chp && isprint(*chp); chp++) ; *chp = '\0'; safe_str(socket_ident, tbuf1, &bp); safe_chr('@', tbuf1, &bp); --- 5666,5672 ---- socket_ident = ident_id(socketClient, &timeout); if (socket_ident) { /* Truncate at first non-printable character */ ! for (chp = socket_ident; *chp && isprint((unsigned char) *chp); chp++) ; *chp = '\0'; safe_str(socket_ident, tbuf1, &bp); safe_chr('@', tbuf1, &bp); *** 1_7_6.36/src/boolexp.c Wed, 13 Nov 2002 17:26:14 -0600 dunemush (pennmush/c/39_boolexp.c 1.1.1.17.1.1.1.13 660) --- 1_7_6.56(w)/src/boolexp.c Mon, 09 Dec 2002 14:04:26 -0600 dunemush (pennmush/c/39_boolexp.c 1.1.1.17.1.1.1.13.1.2 660) *************** *** 468,474 **** static void skip_whitespace() { ! while (*parsebuf && isspace(*parsebuf)) parsebuf++; } --- 468,474 ---- static void skip_whitespace() { ! while (*parsebuf && isspace((unsigned char) *parsebuf)) parsebuf++; } *************** *** 513,519 **** } /* strip trailing whitespace */ *p-- = '\0'; ! while (isspace(*p)) *p-- = '\0'; /* do the match */ if (loading_db) { --- 513,519 ---- } /* strip trailing whitespace */ *p-- = '\0'; ! while (isspace((unsigned char) *p)) *p-- = '\0'; /* do the match */ if (loading_db) { *************** *** 574,580 **** } /* strip trailing whitespace */ *p-- = '\0'; ! while (isspace(*p)) *p-- = '\0'; /* check for an attribute */ b = test_atr(tbuf1, ':'); --- 574,580 ---- } /* strip trailing whitespace */ *p-- = '\0'; ! while (isspace((unsigned char) *p)) *p-- = '\0'; /* check for an attribute */ b = test_atr(tbuf1, ':'); *************** *** 692,698 **** } /* strip trailing whitespace */ *p-- = '\0'; ! while (isspace(*p)) *p-- = '\0'; upcasestr(tbuf1); if (!good_atr_name(tbuf1)) { --- 692,698 ---- } /* strip trailing whitespace */ *p-- = '\0'; ! while (isspace((unsigned char) *p)) *p-- = '\0'; upcasestr(tbuf1); if (!good_atr_name(tbuf1)) { *** 1_7_6.36/src/access.c Mon, 29 Apr 2002 12:03:38 -0500 dunemush (pennmush/c/43_access.c 1.11.1.2.1.2 660) --- 1_7_6.56(w)/src/access.c Mon, 09 Dec 2002 14:04:26 -0600 dunemush (pennmush/c/43_access.c 1.11.1.2.1.4 660) *************** *** 196,202 **** *p = '\0'; /* Find beginning of line; ignore blank lines */ p = buf; ! if (*p && isspace(*p)) p++; if (*p && *p != '#') { can = cant = 0; --- 196,202 ---- *p = '\0'; /* Find beginning of line; ignore blank lines */ p = buf; ! if (*p && isspace((unsigned char) *p)) p++; if (*p && *p != '#') { can = cant = 0; *************** *** 208,218 **** } else { if ((comment = strchr(p, '#'))) { *comment++ = '\0'; ! while (*comment && isspace(*comment)) comment++; } /* Move past the host name */ ! while (*p && !isspace(*p)) p++; if (*p) *p++ = '\0'; --- 208,218 ---- } else { if ((comment = strchr(p, '#'))) { *comment++ = '\0'; ! while (*comment && isspace((unsigned char) *comment)) comment++; } /* Move past the host name */ ! while (*p && !isspace((unsigned char) *p)) p++; if (*p) *p++ = '\0'; *** 1_7_6.36/hdrs/version.h Mon, 11 Nov 2002 20:59:15 -0600 dunemush (pennmush/c/47_version.h 1.32.1.2.1.7.1.9.1.1.1.17 660) --- 1_7_6.56(w)/hdrs/version.h Mon, 09 Dec 2002 14:04:32 -0600 dunemush (pennmush/c/47_version.h 1.32.1.2.1.7.1.9.1.1.1.17.1.1 660) *************** *** 1,2 **** ! #define VERSION "PennMUSH version 1.7.6 patchlevel 0 [11/11/2002]" ! #define SHORTVN "PennMUSH 1.7.6p0" --- 1,2 ---- ! #define VERSION "PennMUSH version 1.7.6 patchlevel 1 [12/08/2002]" ! #define SHORTVN "PennMUSH 1.7.6p1" *** 1_7_6.36/hdrs/conf.h Fri, 01 Nov 2002 10:47:06 -0600 dunemush (pennmush/d/20_conf.h 1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.5.1.1.1.1.1.1.1.1.1.2.1.1.2.1.2.13 660) --- 1_7_6.56(w)/hdrs/conf.h Mon, 09 Dec 2002 14:04:32 -0600 dunemush (pennmush/d/20_conf.h 1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.5.1.1.1.1.1.1.1.1.1.2.1.1.2.1.2.13.1.1 660) *************** *** 338,343 **** --- 338,344 ---- #define WIZ_NOAENTER (options.wiz_noaenter) #define USE_IDENT (options.use_ident) #define IDENT_TIMEOUT (options.ident_timeout) + #define USE_DNS (options.use_dns) #define MUSH_IP_ADDR (options.ip_addr) #define MAX_ATTRCOUNT (options.max_attrcount) #define FLOAT_PRECISION (options.float_precision) *** 1_7_6.36/src/mysocket.c Thu, 30 May 2002 12:14:33 -0500 dunemush (pennmush/f/0_mysocket.c 1.16.1.1.1.1.1.1.1.4.1.4.1.3 660) --- 1_7_6.56(w)/src/mysocket.c Mon, 09 Dec 2002 14:04:28 -0600 dunemush (pennmush/f/0_mysocket.c 1.16.1.1.1.1.1.1.1.4.1.4.1.6 660) *************** *** 105,112 **** static char port[NI_MAXSERV]; if (getnameinfo(host, len, hostname, sizeof hostname, port, sizeof port, ! (options.use_dns ? 0 : NI_NUMERICHOST) | NI_NUMERICSERV) != ! 0) { return NULL; } hi.hostname = hostname; --- 105,111 ---- static char port[NI_MAXSERV]; if (getnameinfo(host, len, hostname, sizeof hostname, port, sizeof port, ! (USE_DNS ? 0 : NI_NUMERICHOST) | NI_NUMERICSERV) != 0) { return NULL; } hi.hostname = hostname; *************** *** 941,947 **** for (sptr = &search[0]; sptr < &search[nsearch]; sptr++) { #ifdef IPv4 /* 4check for an IPv4 dotted-decimal string */ ! if (isdigit(sptr->host[0])) { struct in_addr inaddr; if (inet_pton(AF_INET, sptr->host, &inaddr) == 1) { --- 940,946 ---- for (sptr = &search[0]; sptr < &search[nsearch]; sptr++) { #ifdef IPv4 /* 4check for an IPv4 dotted-decimal string */ ! if (isdigit((unsigned char) sptr->host[0])) { struct in_addr inaddr; if (inet_pton(AF_INET, sptr->host, &inaddr) == 1) { *************** *** 959,965 **** #ifdef HAS_IPV6 /* 4check for an IPv6 hex string */ ! if ((isxdigit(sptr->host[0]) || sptr->host[0] == ':') && (strchr(sptr->host, ':') != NULL)) { struct in6_addr in6addr; --- 958,964 ---- #ifdef HAS_IPV6 /* 4check for an IPv6 hex string */ ! if ((isxdigit((unsigned char) sptr->host[0]) || sptr->host[0] == ':') && (strchr(sptr->host, ':') != NULL)) { struct in6_addr in6addr; *************** *** 1306,1312 **** int port, rc, nfound; nfound = 0; ! if (isdigit(serv[0])) { /* check for port number string first */ port = (int) htons((unsigned short) atoi(serv)); if (hintsp->ai_socktype) { /* 4caller specifies socket type */ --- 1305,1311 ---- int port, rc, nfound; nfound = 0; ! if (isdigit((unsigned char) serv[0])) { /* check for port number string first */ port = (int) htons((unsigned short) atoi(serv)); if (hintsp->ai_socktype) { /* 4caller specifies socket type */ *** 1_7_6.36/hdrs/case.h Wed, 06 Sep 2000 20:17:09 -0500 dunemush (pennmush/f/23_case.h 1.1 660) --- 1_7_6.56(w)/hdrs/case.h Mon, 09 Dec 2002 14:04:32 -0600 dunemush (pennmush/f/23_case.h 1.2 660) *************** *** 4,13 **** #include "config.h" #ifdef HAS_SAFE_TOUPPER ! #define DOWNCASE(x) tolower(x) ! #define UPCASE(x) toupper(x) #else ! #define DOWNCASE(x) (isupper(x) ? tolower(x) : (x)) ! #define UPCASE(x) (islower(x) ? toupper(x) : (x)) #endif #endif /* CASE_H */ --- 4,13 ---- #include "config.h" #ifdef HAS_SAFE_TOUPPER ! #define DOWNCASE(x) tolower((unsigned char)x) ! #define UPCASE(x) toupper((unsigned char)x) #else ! #define DOWNCASE(x) (isupper((unsigned char)x) ? tolower((unsigned char)x) : (x)) ! #define UPCASE(x) (islower((unsigned char)x) ? toupper((unsigned char)x) : (x)) #endif #endif /* CASE_H */ *** 1_7_6.36/win32/pennmush.vcproj Tue, 26 Nov 2002 14:52:53 -0600 dunemush (pennmush/g/18_pennmush.v 1.3 660) --- 1_7_6.56(w)/win32/pennmush.vcproj Wed, 27 Nov 2002 18:41:25 -0600 dunemush (pennmush/g/18_pennmush.v 1.4 600) *************** *** 1,731 **** ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! --- 1,473 ---- ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! *** 1_7_6.36/INSTALL Mon, 11 Nov 2002 20:39:30 -0600 dunemush (pennmush/g/20_INSTALL 1.1 600) --- 1_7_6.56(w)/INSTALL Sun, 08 Dec 2002 22:42:30 -0600 dunemush (pennmush/g/20_INSTALL 1.2 600) *************** *** 101,106 **** --- 101,107 ---- b. Compile with the Cygwin unix emulation tools (http://www.cygwin.com) In addition to the base cygwin stuff, you'll want the following packages: binutils, gcc, make, patch, perl, exim-4.10-1 source code + (gcc 3.2 is recommended.) These are also recommended: gettext, gettext-devel, indent, vim or emacs It is recommended that you install the tools under C:\CYGWIN and