This is patch10 to PennMUSH 1.8.0. After applying this patch, you will have version 1.8.0p10 To apply this patch, save it to a file in your top-level MUSH directory, and do the following: patch -p1 < 1.8.0-patch10 make clean 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. On the off chance they appear not to be, simply rm them and re-run make. Then @shutdown and restart your MUSH. - Alan/Javelin In this patch: Minor changes: * Row and field separators in sql() may now by more than one character. Patch by Walker@M*U*S*H. Fixes: * Fix to GNU libc detection in Configure by Petr Salinger. * Definition of MAILER in options.h.dist made to work by Luke@M*U*S*H. * Fix to double-parsing of row and field separators in sql() by Walker@M*U*S*H. Prereq: 1.8.0p9 *** 1_8_0.83/Patchlevel Mon, 12 Dec 2005 12:24:47 -0600 dunemush (pennmush/5_Patchlevel 1.17.1.11.1.43.1.9 600) --- 1_8_0.87(w)/Patchlevel Sun, 29 Jan 2006 11:44:58 -0600 dunemush (pennmush/5_Patchlevel 1.17.1.11.1.43.1.10 600) *************** *** 1,2 **** Do not edit this file. It is maintained by the official PennMUSH patches. ! This is PennMUSH 1.8.0p9 --- 1,2 ---- Do not edit this file. It is maintained by the official PennMUSH patches. ! This is PennMUSH 1.8.0p10 *** 1_8_0.83/hdrs/version.h Mon, 12 Dec 2005 12:24:47 -0600 dunemush (pennmush/c/47_version.h 1.32.1.2.1.7.1.9.1.1.1.17.1.45.1.10 660) --- 1_8_0.87(w)/hdrs/version.h Mon, 30 Jan 2006 14:04:53 -0600 dunemush (pennmush/c/47_version.h 1.32.1.2.1.7.1.9.1.1.1.17.1.45.1.11 660) *************** *** 1,4 **** #define VERSION "1.8.0" ! #define PATCHLEVEL "9" ! #define PATCHDATE "[12/12/2005]" ! #define NUMVERSION 1008000009 --- 1,4 ---- #define VERSION "1.8.0" ! #define PATCHLEVEL "10" ! #define PATCHDATE "[01/29/2006]" ! #define NUMVERSION 1008000010 *** 1_8_0.83/Configure Thu, 15 Sep 2005 18:13:15 -0500 dunemush (pennmush/d/32_Configure 1.21.1.4.1.1.1.1.1.1.1.7.1.15.1.1.1.2 710) --- 1_8_0.87(w)/Configure Fri, 13 Jan 2006 22:05:46 -0600 dunemush (pennmush/d/32_Configure 1.21.1.4.1.1.1.1.1.1.1.7.1.15.1.1.1.2.1.1 710) *************** *** 3148,3157 **** if $cc $ccflags $ldflags -o gnulibc gnulibc.c $libs >/dev/null 2>&1 && \ ./gnulibc | $contains '^GNU C Library' >/dev/null 2>&1; then val="$define" ! echo "You are using the GNU C Library" else val="$undef" ! echo "You are not using the GNU C Library" fi $rm -f gnulibc* set d_gnulibc --- 3148,3174 ---- if $cc $ccflags $ldflags -o gnulibc gnulibc.c $libs >/dev/null 2>&1 && \ ./gnulibc | $contains '^GNU C Library' >/dev/null 2>&1; then val="$define" ! echo "You are using the GNU C Library" >&4 ! else ! cat >gnulibc.c < ! int main() ! { ! #ifdef __GLIBC__ ! return 0; ! #else ! return 1; ! #endif ! } ! EOM ! if $cc $ccflags $ldflags -o gnulibc gnulibc.c $libs >/dev/null 2>&1 && \ ! ./gnulibc; then ! val="$define" ! echo "You are using the GNU C Library" >&4 else val="$undef" ! echo "You are not using the GNU C Library" >&4 ! fi fi $rm -f gnulibc* set d_gnulibc *** 1_8_0.83/options.h.dist Thu, 06 May 2004 00:31:00 -0500 dunemush (pennmush/d/33_options.h. 1.10.1.1.1.1.1.2.1.1.1.1.1.1.1.3.1.6.1.2.2.3.1.1.1.13 600) --- 1_8_0.87(w)/options.h.dist Fri, 13 Jan 2006 22:05:14 -0600 dunemush (pennmush/d/33_options.h. 1.10.1.1.1.1.1.2.1.1.1.1.1.1.1.3.1.6.1.2.2.3.1.1.1.13.2.1 600) *************** *** 114,120 **** * argument ("get the recipient address from the message header To:"). * If it doesn't, you could probably write a wrapper for it. * Example: #define MAILER "/full/path/to/other/mailer" ! /* #define MAILER /* */ ! #endif --- 114,120 ---- * argument ("get the recipient address from the message header To:"). * If it doesn't, you could probably write a wrapper for it. * Example: #define MAILER "/full/path/to/other/mailer" ! */ ! /* #define MAILER "" /* */ #endif *** 1_8_0.83/game/txt/hlp/pennvOLD.hlp Sat, 01 Oct 2005 09:36:35 -0500 dunemush (pennmush/g/30_pennvOLD.h 1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.2.1.5.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1 660) --- 1_8_0.87(w)/game/txt/hlp/pennvOLD.hlp Mon, 30 Jan 2006 14:04:53 -0600 dunemush (pennmush/g/30_pennvOLD.h 1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.9.1.2.1.5.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1 660) *************** *** 4417,4423 **** For information on a specific patchlevel of one of the versions listed, type 'help p'. For example, 'help 1.7.2p3' ! 1.8.0: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 1.7.7: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40 --- 4417,4423 ---- For information on a specific patchlevel of one of the versions listed, type 'help p'. For example, 'help 1.7.2p3' ! 1.8.0: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 1.7.7: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40 *** 1_8_0.83/game/txt/hlp/pennv180.hlp Mon, 12 Dec 2005 12:24:47 -0600 dunemush (pennmush/h/28_pennv180.h 1.1.1.2.1.1.1.2.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.1.1.1.1.1.1.2.1.2.1.1.1.1 660) --- 1_8_0.87(w)/game/txt/hlp/pennv180.hlp Mon, 30 Jan 2006 14:04:53 -0600 dunemush (pennmush/h/28_pennv180.h 1.1.1.2.1.1.1.2.1.1.1.1.1.2.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.4.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.2.1.1.1.1.1.1.1.2.1.2.1.1.1.1.1.1.1.1.1.1 660) *************** *** 1,4 **** ! & 1.8.0p9 & changes This is a list of changes in this patchlevel which are probably of interest to players. More information about new commands and functions --- 1,4 ---- ! & 1.8.0p10 & changes This is a list of changes in this patchlevel which are probably of interest to players. More information about new commands and functions *************** *** 11,16 **** --- 11,29 ---- A list of the patchlevels associated with each release can be read in 'help patchlevels'. + Version 1.8.0 patchlevel 10 January 29, 2006 + + Minor changes: + * Row and field separators in sql() may now by more than one + character. Patch by Walker@M*U*S*H. + Fixes: + * Fix to GNU libc detection in Configure by Petr Salinger. + * Definition of MAILER in options.h.dist made to work by Luke@M*U*S*H. + * Fix to double-parsing of row and field separators in sql() + by Walker@M*U*S*H. + + + & 1.8.0p9 Version 1.8.0 patchlevel 9 December 12, 2005 Fixes: *** 1_8_0.83/src/sql.c Sat, 20 Aug 2005 19:48:00 -0500 dunemush (pennmush/h/16_sql.c 1.9 660) --- 1_8_0.87(w)/src/sql.c Mon, 30 Jan 2006 14:04:52 -0600 dunemush (pennmush/h/16_sql.c 1.11 660) *************** *** 35,42 **** static MYSQL *mysql_struct = NULL; #define MYSQL_RETRY_TIMES 3 ! static int safe_sql_query(dbref player, char *q_string, char row_delim, ! char field_delim, char *buff, char **bp); static int sql_init(void); void --- 35,42 ---- static MYSQL *mysql_struct = NULL; #define MYSQL_RETRY_TIMES 3 ! static int safe_sql_query(dbref player, char *q_string, char *rowsep, ! char *fieldsep, char *buff, char **bp); static int sql_init(void); void *************** *** 83,92 **** return 0; } - #define print_sep(s,b,p) if (s) safe_chr(s,b,p) - static int ! safe_sql_query(dbref player, char *q_string, char row_delim, char field_delim, char *buff, char **bp) { MYSQL_RES *qres; --- 83,90 ---- return 0; } static int ! safe_sql_query(dbref player, char *q_string, char *rowsep, char *fieldsep, char *buff, char **bp) { MYSQL_RES *qres; *************** *** 152,162 **** i = 0; while ((row_p = mysql_fetch_row(qres)) != NULL) { if (i++ > 0) { ! print_sep(row_delim, buff, bp); } for (j = 0; j < got_fields; j++) { if (j > 0) { ! print_sep(field_delim, buff, bp); } if (row_p[j] && *row_p[j]) if (safe_str(row_p[j], buff, bp)) --- 150,160 ---- i = 0; while ((row_p = mysql_fetch_row(qres)) != NULL) { if (i++ > 0) { ! safe_str(rowsep, buff, bp); } for (j = 0; j < got_fields; j++) { if (j > 0) { ! safe_str(fieldsep, buff, bp); } if (row_p[j] && *row_p[j]) if (safe_str(row_p[j], buff, bp)) *************** *** 192,198 **** FUNCTION(fun_sql) { ! char row_delim, field_delim; if (!Sql_Ok(executor)) { safe_str(T(e_perm), buff, bp); --- 190,197 ---- FUNCTION(fun_sql) { ! char *rowsep = (char *) " "; ! char *fieldsep = (char *) " "; if (!Sql_Ok(executor)) { safe_str(T(e_perm), buff, bp); *************** *** 200,234 **** } if (nargs >= 2) { ! /* we have a delimiter in args[2]. Got to parse it */ ! char insep[BUFFER_LEN]; ! char *isep = insep; ! const char *arg2 = args[1]; ! process_expression(insep, &isep, &arg2, executor, caller, enactor, ! PE_DEFAULT, PT_DEFAULT, pe_info); ! *isep = '\0'; ! strcpy(args[1], insep); } if (nargs >= 3) { ! /* we have a delimiter in args[3]. Got to parse it */ ! char insep[BUFFER_LEN]; ! char *isep = insep; ! const char *arg3 = args[2]; ! process_expression(insep, &isep, &arg3, executor, caller, enactor, ! PE_DEFAULT, PT_DEFAULT, pe_info); ! *isep = '\0'; ! strcpy(args[2], insep); } ! if (!delim_check(buff, bp, nargs, args, 2, &row_delim)) ! return; ! if (nargs < 3) ! field_delim = ' '; ! else if (!delim_check(buff, bp, nargs, args, 3, &field_delim)) ! return; ! ! safe_sql_query(executor, args[0], row_delim, field_delim, buff, bp); } --- 199,214 ---- } if (nargs >= 2) { ! /* we have a row separator in args[1]. */ ! rowsep = args[1]; } if (nargs >= 3) { ! /* we have a field separator in args[2]. Got to parse it */ ! fieldsep = args[2]; } ! safe_sql_query(executor, args[0], rowsep, fieldsep, buff, bp); } *************** *** 261,267 **** COMMAND (cmd_sql) { ! safe_sql_query(player, arg_left, ' ', ' ', NULL, NULL); } #else --- 241,247 ---- COMMAND (cmd_sql) { ! safe_sql_query(player, arg_left, NULL, NULL, NULL, NULL); } #else *** 1_8_0.83/CHANGES.180 Mon, 12 Dec 2005 12:24:47 -0600 dunemush (pennmush/h/21_CHANGES.18 1.53 600) --- 1_8_0.87(w)/CHANGES.180 Sun, 29 Jan 2006 11:45:07 -0600 dunemush (pennmush/h/21_CHANGES.18 1.56 600) *************** *** 12,17 **** --- 12,29 ---- ========================================================================== + Version 1.8.0 patchlevel 10 January 29, 2006 + + Minor changes: + * Row and field separators in sql() may now by more than one + character. Patch by Walker@M*U*S*H. + Fixes: + * Fix to GNU libc detection in Configure by Petr Salinger. + * Definition of MAILER in options.h.dist made to work by Luke@M*U*S*H. + * Fix to double-parsing of row and field separators in sql() + by Walker@M*U*S*H. + + Version 1.8.0 patchlevel 9 December 12, 2005 Fixes: