PennMUSH Community

Changeset 718

Show
Ignore:
Timestamp:
03/11/07 20:37:38 (1 year ago)
Author:
penndev
Message:

PennMUSH 1.8.3p1 release candidate.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • 1.8.3/trunk/CHANGES.182

    r654 r718  
    1414 
    1515========================================================================== 
     16 
     17Version 1.8.2 patchlevel 3                      March 11, 2007 
     18 
     19Fixes: 
     20  * Unterminated buffer in sortkey() fixed. Reported by Balerion. 
     21    Patch by Javelin. 
     22  * Memory leaks in setunion() and revwords() fixed by Javelin. 
     23  * Crash bug in speak() fixed. Reported by Trinsec. Patch by Javelin. 
     24  * Crash bug in buy fixed. Reported by Amy. Patch by Javelin. 
     25  * If we should fail to clear a semaphore attribute for some 
     26    reason (e.g., it's the branch of an attribute tree), reset 
     27    the semaphore count on the attribute to 0. Patch by Javelin. 
     28  * iter() dealt badly with freeing buffers when CPU_LIMIT or 
     29    function_invocation_limit was hit. Found by Ashen-Shugar. [GM] 
     30  * @ps/all displayed the wrong  queue entry count for mortals. 
     31    Reported by Cheetah. [SW] 
     32  * @hook/override of say would get an extra leading " if that was 
     33    used instead of the literal say command. Reported by Tuxedo Ian. 
     34    [SW] 
     35  * Fixed a bug where speech seemed to come from the wrong  
     36    object for nospoof information. Reported by Jules. [SW] 
     37  * The help entry for @poll failed to mention @poll/clear. 
     38    Reported by Cooee. [SW] 
    1639 
    1740Version 1.8.2 patchlevel 2                      January 27, 2007 
  • 1.8.3/trunk/CHANGES.183

    r654 r718  
    1515========================================================================== 
    1616 
     17Version 1.8.3 patchlevel 1                      March 11, 2007 
     18 
     19Minor changes: 
     20  * page command now processes page output through PAGEFORMAT 
     21    attribute, allowing user-set page messages. [GM] 
     22  * sql_host configuration option now permits alternate tcp port. 
     23    Suggested by Mercutio. Patch by Javelin. 
     24  * Refactoring of fun_stringsecs to help function etime_to_secs. 
     25    Patch by Javelin. 
     26  * %1 in @aconnect works like in @adisconnect. Patch by Javelin. 
     27 
     28Fixes: 
     29  * restart script once again includes DATEMSK export for 
     30    extended convtime support. Reported by KimikoMuffin. 
     31  * Memory leak in 1.8.3p0 regedit fixed. 
     32  * Fixes included from 1.8.2p3. 
     33  * Document change in @chan/title behavior with commas. 
     34 
    1735Version 1.8.3 patchlevel 0                      January 27, 2007 
    1836 
    1937Major changes: 
    20   * Rewrite of color handling. [GM] 
     38  * Rewrite of color handling. [GM] 
    2139 
    2240Minor changes: 
  • 1.8.3/trunk/Configure

    r525 r718  
    421421d_mysql='' 
    422422libmysqlclient='' 
     423d_postgresql='' 
     424libpq='' 
    423425glibpth='' 
    424426libpth='' 
     
    49654967fi 
    49664968 
     4969: see if we should include -lpq 
     4970echo " " 
     4971 
     4972d_postgresql="$undef" 
     4973 
     4974if $test "x$no_postgresql" = "x"; then 
     4975 
     4976  libpq="-lpq" 
     4977 
     4978  $cat > test_postgresql.c <<EOM 
     4979#include <stdio.h> 
     4980#include <stdlib.h> 
     4981#include <postgresql/libpq-fe.h> 
     4982 
     4983int main(int argc, char **argv) { 
     4984  const char *conninfo = "dbname = postgres"; 
     4985  PGconn *conn; 
     4986  conn = PQconnectdb(conninfo); 
     4987  PQfinish(conn); 
     4988  exit(0); 
     4989} 
     4990EOM 
     4991 
     4992  if $cc $ccflags $ldflags -o test_postgresql test_postgresql.c $libs $libpq >/dev/null 2>&1 ; 
     4993  then 
     4994      echo 'You have postgresql...' >&4 
     4995      version=`./test_postgresql` 
     4996      if $test $? -eq 0; then 
     4997        d_postgresql="$define" 
     4998      else 
     4999        echo "...but my test program didn't run correctly." >&4 
     5000        libpq='' 
     5001      fi 
     5002  else 
     5003      echo "You don't seem to have postgresql." >&4 
     5004      libpq='' 
     5005  fi 
     5006  $rm -f test_postgresql* core 
     5007 
     5008else 
     5009 
     5010  echo "Skipping postgresql tests." >&4 
     5011  libpq='' 
     5012 
     5013fi 
     5014 
    49675015: see if rename exists 
    49685016set rename d_rename 
     
    70287076d_passnames='$d_passnames' 
    70297077d_portable='$d_portable' 
     7078d_postgresql='$d_postgresql' 
    70307079d_rand='$d_rand' 
    70317080d_random='$d_random' 
     
    71507199libc='$libc' 
    71517200libmysqlclient='$libmysqlclient' 
     7201libpq='$libpq' 
    71527202libpth='$libpth' 
    71537203libs='$libs' 
  • 1.8.3/trunk/MANIFEST

    r654 r718  
    185185src/look.c 
    186186src/malias.c 
     187src/markup.c 
    187188src/match.c 
    188189src/memcheck.c 
  • 1.8.3/trunk/Makefile.SH

    r654 r718  
    4949CCFLAGS=$optimize -I.. -I../hdrs $ccflags $warnings 
    5050LDFLAGS=$ldflags 
    51 CLIBS=$libs $cryptlib $libssl $libmysqlclient 
     51CLIBS=$libs $cryptlib $libssl $libmysqlclient $libpq 
    5252INSTALL=$install 
    5353INSTALLDIR=$installdir 
  • 1.8.3/trunk/Patchlevel

    r654 r718  
    11Do not edit this file. It is maintained by the official PennMUSH patches. 
    2 This is PennMUSH 1.8.3p0 
     2This is PennMUSH 1.8.3p1 
  • 1.8.3/trunk/README.SQL

    r515 r718  
    99 
    1010  * MySQL 
     11  * PostgresQL (from 1.8.3p2) 
    1112 
    1213This document explains how to use (or avoid) SQL with PennMUSH, and covers 
     
    1718   III. SQL setup tips 
    1819 
    19 I. Compiling with MySQL 
     20I. Compiling with/without SQL 
     21 
     22In general, Configure attempts to detect all support sql client 
     23libraries on the host, and will link with all of them, permitting 
     24you to select which platform you want at runtime. You can selectively 
     25prevent linking with client libraries that are present on your 
     26system, as well; this is described below. 
     27 
     28I.a. MySQL 
    2029 
    2130  The Configure script distributed with PennMUSH automatically detects 
     
    3746  to fix this. 
    3847 
     48I.b. PostgresQL 
     49 
     50  The Configure script distributed with PennMUSH automatically detects 
     51  the PostgresQL client library (libpq) and attempts to link 
     52  them into the executable, defining HAS_POSTGRESQL in config.h 
     53 
     54  If you want to avoid linking these libraries on systems where they 
     55  are present, use the '-D no_postgresql' switch to Configure. 
     56 
     57  If you installed PostgresQL from a binary package (e.g. rpm or apt), 
     58  you should be sure that your system also has the development 
     59  package (usually postgresql-dev, or libpq or similar) 
     60 
     61  If you think you have posgresql libraries and header files but 
     62  Configure isn't finding them, they may be in an unusual location on 
     63  your system.  Creating symbolic links from the header directory to 
     64  /usr/include/postgresql and from the libraries in /usr/lib (or adding 
     65  the postgresql library directory to your /etc/ld.so.conf and running 
     66  ldconfig) are the easiest ways to fix this. 
     67 
    3968II. Mush configuration overview 
    4069 
     
    4271 
    4372  sql_platform provides the name of the SQL database server software 
    44   that will be used for connections. It current takes one of two 
    45   values: "disabled" (no SQL) or "mysql". If not specified, it  
    46   defaults to disabled. 
     73  that will be used for connections. It current takes one of three 
     74  values: "disabled" (no SQL), "mysql", or "postgresql". If not specified, 
     75  it defaults to disabled. 
    4776 
    4877  sql_host gives the name of the host running the SQL server. 
    4978  It defaults to 127.0.0.1, which makes a TCP connection to the  
    5079  local host. The keyword "localhost" instead makes a domain socket 
    51   (Unix) or named pipe (Windows) connection. 
     80  (Unix) or named pipe (Windows) connection under MySQL. 
     81  You can also specify an alternate port by setting sql_host to 
     82  hostname:port (e.g. 127.0.0.1:5444). 
    5283 
    5384  sql_database gives the name of the database that contains the  
     
    117148    Are you pretty sure you would like to implement this [yes/no]: yes 
    118149 
     150  B. PostgresQL 
     151 
     152    As the postgres user: 
     153 
     154    % createuser -A -d -P mush 
     155    Enter password for new user:            <=========== 
     156    CREATE USER 
     157 
     158    % createdb -U mush mush 
     159    Password:                   <=========== 
     160    CREATE DATABASE 
     161 
  • 1.8.3/trunk/config_h.SH

    r517 r718  
    850850#$d_mysql HAS_MYSQL /**/ 
    851851 
     852/* HAS_POSTGRESQL: 
     853 *     Defined if postgresql client libraries are available. 
     854 */ 
     855#$d_postgresql HAS_POSTGRESQL /**/ 
     856 
    852857/* HAS_OPENSSL: 
    853858 *     Defined if openssl 0.9.6+ is available. 
  • 1.8.3/trunk/game/mushcnf.dst

    r527 r718  
    559559 
    560560# What SQL server platform should we use? Options include: 
    561 # mysql, disabled (the default) 
     561# mysql, postgresql, disabled (the default) 
    562562sql_platform disabled 
    563563 
    564564# What's the SQL hostname? Use '127.0.0.1' for a TCP connection 
    565 # to the local host, and 'localhost' for a domain socket connection. 
     565# to the local host on port 3306, '<hostip>:<port#>' for a TCP 
     566# connection on another port (e.g. 127.0.0.1:3307), and  
     567# the word 'localhost' for a domain socket connection. 
    566568sql_host 127.0.0.1 
    567569 
  • 1.8.3/trunk/game/restart

    r654 r718  
    139139 
    140140DATEMSK="${GAMEDIR}/getdate.template" 
     141export DATEMSK 
    141142 
    142143LC_ALL=$LANG LANG=$LANG ./netmush $GAMEDIR/$CONF_FILE & 
  • 1.8.3/trunk/game/txt/hlp/pennchat.hlp

    r654 r718  
    100100  when you speak on the channel. If you leave the channel, your 
    101101  title is cleared; use @channel/gag instead (see help @channel3). 
     102  You should escape any commas in your title with backslashes. 
    102103 
    103104  See "help @channel3" for more. 
  • 1.8.3/trunk/game/txt/hlp/penncmd.hlp

    r654 r718  
    148148  when a player connects in that location or zone (or, in the case of 
    149149  the master room, anywhere). 
     150 
     151  One descriptor variable is passed to @aconnect: 
     152  %1 = number of player connections (1 if this is an initial connect) 
    150153 
    151154See also: @adisconnect, ACTION LISTS 
     
    25882591 
    25892592  This changes your password. Please note that passwords ARE case-sensitive. 
    2590    
     2593& @pageformat 
     2594  @pageformat <object> [=<message>] 
     2595 
     2596  Sets the message that is seen when <object> receives a page. <message> is 
     2597  evaluated. 
     2598 
     2599  %0 will be set to the page message. 
     2600  %1 will be set to ':' ';' or '"' for pose, semipose and normal page, 
     2601                    respectively, 
     2602  %2 will be set to the alias of the pager, if any. 
     2603  %3 will be a space-separated list of recipient dbrefs. 
     2604 
     2605  To obtain 'page_aliases' behavior: 
     2606  > @pageformat me=[setq(0,%n[if(%2,%b(%2))],1,switch(%3,%!,,itemize(iter(%3, 
     2607     name(##),%b,|),|)))][switch(%1,",%q0 pages[if(%q1,%b%q1)]: %0,:,From  
     2608     afar[if(%q1,%b(to %q1))]\, %q0 %0,From afar[if(%q1,%b(to %q1))]\, %q0%0)] 
     2609 
     2610  To obtain no 'page_aliases' behavior: 
     2611  > @pageformat me=[setq(1,switch(%3,%!,,itemize(iter(%3,name(##),%b,|),|)))] 
     2612     [switch(%1,",%n pages[if(%q1,%b%q1)]: %0,:,From afar 
     2613     [if(%q1,%b(to %q1))]\, %n %0,From afar[if(%q1,%b(to %q1))]\, %n%0)] 
     2614   
     2615See also: page, speak() 
    25912616& @payment 
    25922617  @payment <object> [=<message>] 
     
    26932718  See also @emit, @oemit, @remit, NOSPOOF, and SPOOFING. 
    26942719& @poll 
     2720  @poll 
    26952721  @poll <poll question> 
    2696   This wizard-only command sets the "poll" - the Doing question. If 
    2697   "@poll" is used by itself, the question is reset to the default 
    2698   string "Doing". It can also be used by those with the poll @power. 
     2722  @poll/clear 
     2723 
     2724  This command manipulate the message at the top of WHO/DOING. By itself, 
     2725  it displays the current poll. Wizards and those with the poll @power can 
     2726  set or clear the message. 
    26992727 
    27002728See also: @doing, WHO, DOING 
     
    40174045  If you have already paged someone since connecting, just typing: 
    40184046 
    4019     page <message> 
     4047    'page <message>' or 'page =<message>' 
    40204048 
    40214049  will send the message to the last person paged. You cannot page a  
     
    40424070  square brackets, in front of the message, in a fashion similar to 
    40434071  the way NOSPOOF flags emits. 
     4072 
     4073  When a player is paged, their PAGEFORMAT attribute is checked, and if 
     4074  exists, the page as viewed by the player is set to the results of 
     4075  calling PAGEFORMAT. See help @pageformat 
    40444076 
    40454077  Page takes five switches: /list, /blind, /noeval, /override, and /port.  
     
    40544086  including connections that have not yet logged into a player. 
    40554087   
    4056 See also: @lock, @alias, pose, :, ;, HAVEN, NOSPOOF, FLAGS 
     4088See also: @lock, @alias, @pageformat, pose, :, ;, HAVEN, NOSPOOF, FLAGS 
    40574089& : 
    40584090& ; 
  • 1.8.3/trunk/game/txt/hlp/pennv182.hlp

    r654 r718  
     1& 1.8.2p3 
     2Version 1.8.2 patchlevel 3                      March 11, 2007 
     3 
     4Fixes: 
     5  * Unterminated buffer in sortkey() fixed. Reported by Balerion. 
     6    Patch by Javelin. 
     7  * Memory leaks in setunion() and revwords() fixed by Javelin. 
     8  * Crash bug in speak() fixed. Reported by Trinsec. Patch by Javelin. 
     9  * Crash bug in buy fixed. Reported by Amy. Patch by Javelin. 
     10  * If we should fail to clear a semaphore attribute for some 
     11    reason (e.g., it's the branch of an attribute tree), reset 
     12    the semaphore count on the attribute to 0. Patch by Javelin. 
     13  * iter() dealt badly with freeing buffers when CPU_LIMIT or 
     14    function_invocation_limit was hit. Found by Ashen-Shugar. [GM] 
     15  * @ps/all displayed the wrong  queue entry count for mortals. 
     16    Reported by Cheetah. [SW] 
     17  * @hook/override of say would get an extra leading " if that was 
     18    used instead of the literal say command. Reported by Tuxedo Ian. 
     19    [SW] 
     20  * Fixed a bug where speech seemed to come from the wrong  
     21    object for nospoof information. Reported by Jules. [SW] 
     22  * The help entry for @poll failed to mention @poll/clear. 
     23    Reported by Cooee. [SW] 
     24 
    125& 1.8.2p2 
    226Version 1.8.2 patchlevel 2                      January 27, 2007 
     
    1842    of the name for @ahear/@aahear/@amhear. [SW] 
    1943  * Fixed the distribution of random numbers with a huge range. Reported 
    20     by Luke. 
     44    by Luke.  
     45 
    2146& 1.8.2p1 
    2247Version 1.8.2 patchlevel 1                      November 26, 2006 
  • 1.8.3/trunk/game/txt/hlp/pennv183.hlp

    r654 r718  
    1 & 1.8.3p0 
     1& 1.8.3p1 
    22& changes 
    33This is a list of changes in this patchlevel which are probably of 
     
    1212be read in 'help patchlevels'. 
    1313 
     14Version 1.8.3 patchlevel 1                      March 11, 2007 
     15 
     16Minor changes: 
     17  * page command now processes page output through PAGEFORMAT 
     18    attribute, allowing user-set page messages. [GM] 
     19  * sql_host configuration option now permits alternate tcp port. 
     20    Suggested by Mercutio. Patch by Javelin. 
     21  * Refactoring of fun_stringsecs to help function etime_to_secs. 
     22    Patch by Javelin. 
     23  * %1 in @aconnect works like in @adisconnect. Patch by Javelin. 
     24 
     25Fixes: 
     26  * restart script once again includes DATEMSK export for 
     27    extended convtime support. Reported by KimikoMuffin. 
     28  * Memory leak in 1.8.3p0 regedit fixed. 
     29  * Fixes included from 1.8.2p3. 
     30  * Document change in @chan/title behavior with commas. 
     31 
     32& 1.8.3p0 
    1433Version 1.8.3 patchlevel 0                      January 27, 2007 
    1534 
    1635Major changes: 
    17   * Rewrite of color handling. [GM] 
     36  * Rewrite of color handling. [GM] 
    1837 
    1938Minor changes: 
  • 1.8.3/trunk/game/txt/hlp/pennvOLD.hlp

    r654 r718  
    44184418type 'help <version>p<patchlevel>'. For example, 'help 1.7.2p3' 
    44194419 
    4420 1.8.3: 0 
    4421 1.8.2: 0, 1 
     44201.8.3: 0, 1 
     44211.8.2: 0, 1, 2, 3 
    442244221.8.1: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 
    442344231.8.0: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13 
  • 1.8.3/trunk/hdrs/atr_tab.h

    r519 r718  
    144144  {"OZLEAVE", AF_NOPROG | AF_PREFIXMATCH, NULL_CHUNK_REFERENCE, 0, NULL}, 
    145145  {"PAYMENT", AF_NOPROG | AF_PREFIXMATCH, NULL_CHUNK_REFERENCE, 0, NULL}, 
     146  {"PAGEFORMAT", AF_NOPROG | AF_PREFIXMATCH, NULL_CHUNK_REFERENCE, 0, NULL}, 
    146147  {"PRICELIST", AF_NOPROG | AF_PREFIXMATCH, NULL_CHUNK_REFERENCE, 0, NULL}, 
    147148  {"PREFIX", AF_NOPROG | AF_PREFIXMATCH, NULL_CHUNK_REFERENCE, 0, NULL}, 
  • 1.8.3/trunk/hdrs/conf.h

    r525 r718  
    266266  char trace_log[256]; /**< File to log trace data */ 
    267267  char checkpt_log[256]; /**< File to log checkpoint data */ 
    268 #ifdef HAS_MYSQL 
    269268  char sql_platform[256]; /**< Type of SQL server, or "disabled" */ 
    270269  char sql_host[256]; /**< Hostname of sql server */ 
     
    272271  char sql_password[256]; /**< Password for sql */ 
    273272  char sql_database[256]; /**< Database for sql */ 
    274 #endif 
    275273}; 
    276274 
     
    433431#define TRACELOG (options.trace_log) 
    434432#define CHECKLOG (options.checkpt_log) 
    435 #ifdef HAS_MYSQL 
    436433#define SQL_PLATFORM (options.sql_platform) 
    437434#define SQL_HOST (options.sql_host) 
     
    439436#define SQL_USER (options.sql_username) 
    440437#define SQL_PASS (options.sql_password) 
    441 #endif 
    442438 
    443439#define CHUNK_SWAP_FILE (options.chunk_swap_file) 
  • 1.8.3/trunk/hdrs/externs.h

    r654 r718  
    257257extern void do_unlink(dbref player, const char *name); 
    258258extern dbref do_clone(dbref player, char *name, char *newname, int preserve); 
     259 
     260/* From funtime.c */ 
     261extern int etime_to_secs(char *str1, int *secs); 
    259262 
    260263/* From game.c */ 
     
    527530             char *ret, dbref executor, dbref enactor, 
    528531             PE_Info * pe_info); 
     532    extern int call_attrib(dbref thing, const char *attrname, 
     533               const char *wenv_args[], int wenv_argc, char *ret, 
     534               dbref enactor, PE_Info * pe_info); 
    529535    extern int member(dbref thing, dbref list); 
    530536    extern int recursive_member(dbref disallow, dbref from, int count); 
  • 1.8.3/trunk/hdrs/version.h

    r654 r718  
    11#define VERSION "1.8.3" 
    2 #define PATCHLEVEL "0
    3 #define PATCHDATE "[01/27/2007]" 
    4 #define NUMVERSION 1008003000 
     2#define PATCHLEVEL "1
     3#define PATCHDATE "[03/11/2007]" 
     4#define NUMVERSION 1008003001 
  • 1.8.3/trunk/src/attrib.c

    r654 r718  
    448448      num_new++; 
    449449    } 
     450    /* Only GOD can create an AF_NODUMP attribute (used for semaphores) 
     451     * or add a leaf to a tree with such an attribute 
     452     */ 
     453    if ((AL_FLAGS(atr) & AF_NODUMP) && (player != GOD)) { 
     454      missing_name[0] = '\0'; 
     455      return AE_ERROR; 
     456    } 
    450457    if (Cannot_Write_This_Attr(player, atr, 1)) { 
    451458      missing_name[0] = '\0'; 
  • 1.8.3/trunk/src/bsd.c

    r654 r718  
    33473347  dbref loc; 
    33483348  char tbuf1[BUFFER_LEN]; 
     3349  char *myenv[2]; 
    33493350  dbref zone; 
    33503351  dbref obj; 
     
    34163417    global_eval_context.rnxt[j] = NULL; 
    34173418  strcpy(global_eval_context.ccom, ""); 
     3419  /* And then load it up, as follows: 
     3420   * %0 (unused, reserved for "reason for disconnect") 
     3421   * %1 (number of connections after connect) 
     3422   */ 
     3423  myenv[0] = NULL; 
     3424  myenv[1] = mush_strdup(unparse_integer(num), "myenv"); 
     3425  for (j = 0; j < 2; j++) 
     3426    global_eval_context.wnxt[j] = myenv[j]; 
    34183427 
    34193428  /* do the person's personal connect action */ 
     
    34473456    (void) queue_attribute(obj, "ACONNECT", player); 
    34483457  } 
     3458  for (j = 0; j < 2; j++) 
     3459    if (myenv[j]) 
     3460      mush_free(myenv[j], "myenv"); 
     3461  for (j = 0; j < 10; j++) 
     3462    global_eval_context.wnxt[j] = NULL; 
     3463  strcpy(global_eval_context.ccom, ""); 
    34493464} 
    34503465 
     
    37873802  int start, count; 
    37883803  int powered = (*(called_as + 1) != 'M'); 
    3789   int objid = (index(called_as, 'D') != NULL); 
     3804  int objid = (strchr(called_as, 'D') != NULL); 
    37903805 
    37913806  if (!is_strict_integer(args[0]) || !is_strict_integer(args[1])) { 
     
    38453860  dbref victim; 
    38463861  int powered = ((*called_as == 'L') && Priv_Who(executor)); 
    3847   int objid = (index(called_as, 'D') != NULL); 
     3862  int objid = (strchr(called_as, 'D') != NULL); 
    38483863 
    38493864  first = 1; 
  • 1.8.3/trunk/src/command.c

    r566 r718  
    249249  {"@SQL", NULL, cmd_sql, CMD_T_ANY, "WIZARD", "SQL_OK"}, 
    250250#else 
     251#ifdef HAS_POSTGRESQL 
     252  {"@SQL", NULL, cmd_sql, CMD_T_ANY, "WIZARD", "SQL_OK"}, 
     253#else 
    251254  {"@SQL", NULL, cmd_unimplemented, CMD_T_ANY, "WIZARD", "SQL_OK"}, 
     255#endif 
    252256#endif 
    253257  {"@SITELOCK", "BAN CHECK REGISTER REMOVE NAME", cmd_sitelock, 
     
    913917  case SAY_TOKEN: 
    914918    replacer = "SAY"; 
     919#if 0 
     920    /* Messes up hooks when chat_strip_quote is yes. See bug #6677 */ 
    915921    if (CHAT_STRIP_QUOTE) 
    916922      p--;          /* Since 'say' strips out the '"' */ 
     923#endif 
    917924    break; 
    918925  case POSE_TOKEN: 
  • 1.8.3/trunk/src/conf.c

    r654 r718  
    193193  {"pueblo", cf_bool, &options.support_pueblo, 2, 0, "net"} 
    194194  , 
    195 #ifdef HAS_MYSQL 
    196195  {"sql_platform", cf_str, options.sql_platform, sizeof options.sql_platform, 0, 
    197196   "net"} 
     
    208207   NULL} 
    209208  , 
    210 #endif 
    211  
    212209  {"forking_dump", cf_bool, &options.forking_dump, 2, 0, "dump"} 
    213210  , 
     
    11881185#endif 
    11891186  options.mem_check = 0; 
    1190 #ifdef HAS_MYSQL 
    11911187  strcpy(options.sql_platform, "disabled"); 
    11921188  strcpy(options.sql_database, ""); 
     
    11941190  strcpy(options.sql_password, ""); 
    11951191  strcpy(options.sql_host, "127.0.0.1"); 
    1196 #endif 
    11971192} 
    11981193 
     
    16081603  notify(player, T(" The MUSH was compiled with MySQL support.")); 
    16091604#endif 
     1605#ifdef HAS_POSTGRESQL 
     1606  notify(player, T(" The MUSH was compiled with Postgresql support.")); 
     1607#endif 
    16101608 
    16111609#ifdef INFO_SLAVE 
  • 1.8.3/trunk/src/cque.c

    r566 r718  
    124124    num = parse_integer(atr_value(a)); 
    125125  num += am; 
    126   if (num) { 
    127     sprintf(buff, "%d", num); 
    128     (void) atr_add(player, name, buff, GOD, flags); 
    129   } else { 
     126  /* We set the attribute's value to 0 even if we're going to clear 
     127   * it later, because clearing it may fail (perhaps someone's also 
     128   * foolishly using it as a branch in an attribute tree) 
     129   */ 
     130  sprintf(buff, "%d", num); 
     131  (void) atr_add(player, name, buff, GOD, flags); 
     132  if (!num) { 
    130133    (void) atr_clr(player, name, GOD); 
    131134  } 
     
    904907      (*del)++; 
    905908    else if (q_all || (Owner(tmp->player) == victim)) { 
    906       (*self)++; 
    907       if (!q_quiet && (LookQueue(player) 
    908                || Owns(tmp->player, player))) { 
     909      if ((LookQueue(player) 
     910       || Owns(tmp->player, player))) { 
     911    (*self)++; 
     912    if (q_quiet) 
     913      continue; 
    909914    switch (q_type) { 
    910915    case 1:     /* wait queue */ 
    911       notify_format(player, "[%ld]%s:%s", tmp->left - mudtime, 
     916      notify_format(player, "[%ld]%s: %s", tmp->left - mudtime, 
    912917            unparse_object(player, tmp->player), tmp->comm); 
    913918      break; 
    914919    case 2:     /* semaphore queue */ 
    915920      if (tmp->left != 0) { 
    916         notify_format(player, "[#%d/%s/%ld]%s:%s", tmp->sem, 
     921        notify_format(player, "[#%d/%s/%ld]%s: %s", tmp->sem, 
    917922              tmp->semattr, tmp->left - mudtime, 
    918923              unparse_object(player, tmp->player), tmp->comm); 
    919924      } else { 
    920         notify_format(player, "[#%d/%s]%s:%s", tmp->sem, 
     925        notify_format(player, "[#%d/%s]%s: %s", tmp->sem, 
    921926              tmp->semattr, unparse_object(player, tmp->player), 
    922927              tmp->comm); 
     
    924929      break; 
    925930    default:        /* player or object queue */ 
    926       notify_format(player, "%s:%s", unparse_object(player, 
    927                             tmp->player), 
     931      notify_format(player, "%s: %s", unparse_object(player, 
     932                            tmp->player), 
    928933            tmp->comm); 
    929934    } 
  • 1.8.3/trunk/src/filecopy.c

    r515 r718  
    207207  char FileName[256]; 
    208208  if (GetModuleFileName(NULL, FileName, 256) != 0) { 
    209     if (!strcasecmp(rindex(FileName, '\\') + 1, "pennmush.exe")) { 
     209    if (!strcasecmp(strrchr(FileName, '\\') + 1, "pennmush.exe")) { 
    210210      if (CopyFile("pennmush.exe", "pennmush_run.exe", FALSE)) { 
    211211    do_rawlog(LT_ERR, "Successfully copied executable, starting copy."); 
  • 1.8.3/trunk/src/funlist.c

    r654 r718  
    12121212  char outsep[BUFFER_LEN]; 
    12131213  int i; 
    1214   char tbuff[BUFFER_LEN]; 
    1215   char *tp; 
    1216   char const *cp; 
    12171214  char result[BUFFER_LEN]; 
    1218   char *rp; 
    1219   ATTR *attrib; 
    1220   dbref thing; 
     1215  ufun_attrib ufun; 
     1216  char *wenv[1]; 
    12211217 
    12221218  /* sortkey(attr,list,sort_type,delim,osep) */ 
     
    12341230    strcpy(outsep, args[4]); 
    12351231 
    1236   /* Find object and attribute to get sortby function from. */ 
    1237   parse_anon_attrib(executor, args[0], &thing, &attrib); 
    1238   if (!GoodObject(thing) || !attrib || !Can_Read_Attr(executor, thing, attrib)) { 
    1239     free_anon_attrib(attrib); 
    1240     return; 
    1241   } 
    1242   if (!CanEvalAttr(executor, thing, attrib)) { 
    1243     free_anon_attrib(attrib); 
    1244     return; 
    1245   } 
    1246   tp = tbuff; 
    1247   safe_str(atr_value(attrib), tbuff, &tp); 
    1248   *tp = '\0'; 
    1249  
     1232  /* find our object and attribute */ 
     1233  if (!fetch_ufun_attrib(args[0], executor, &ufun, 1)) 
     1234    return; 
    12501235 
    12511236  nptrs = list2arr_ansi(ptrs, MAX_SORTSIZE, args[1], sep); 
     
    12531238  /* Now we make a list of keys */ 
    12541239  for (i = 0; i < nptrs; i++) { 
    1255     global_eval_context.wenv[0] = (char *) ptrs[i]; 
    1256     rp = result; 
    1257     cp = tbuff; 
    1258     process_expression(result, &rp, &cp, 
    1259                thing, executor, enactor, 
    1260                PE_DEFAULT, PT_DEFAULT, pe_info); 
    1261     *rp = '\0'; 
     1240    /* Build our %0 args */ 
     1241    wenv[0] = (char *) ptrs[i]; 
     1242    call_ufun(&ufun, wenv, 2, result, executor, enactor, pe_info); 
    12621243    keys[i] = mush_strdup(result, "sortkey"); 
    12631244  } 
     
    14621443  char sep; 
    14631444  char **a1, **a2; 
    1464   int n1, n2, x1, x2, val
     1445  int n1, n2, x1, x2, val, orign1, orign2
    14651446  int lastx1, lastx2, found; 
    14661447  char *sort_type = ALPHANUM_LIST; 
     
    14811462 
    14821463  /* make arrays out of the lists */ 
    1483   n1 = list2arr_ansi(a1, MAX_SORTSIZE, args[0], sep); 
    1484   n2 = list2arr_ansi(a2, MAX_SORTSIZE, args[1], sep); 
     1464  orign1 = n1 = list2arr_ansi(a1, MAX_SORTSIZE, args[0], sep); 
     1465  orign2 = n2 = list2arr_ansi(a2, MAX_SORTSIZE, args[1], sep); 
    14851466 
    14861467  if (nargs < 4) { 
     
    15901571    } 
    15911572  } 
    1592   freearr(a1, n1); 
    1593   freearr(a2, n2); 
     1573  freearr(a1, orign1); 
     1574  freearr(a2, orign2); 
    15941575  mush_free((Malloc_t) a1, "ptrarray"); 
    15951576  mush_free((Malloc_t) a2, "ptrarray"); 
     
    26062587{ 
    26072588  char **words; 
    2608   int count
     2589  int count, origcount
    26092590  char sep; 
    26102591  char *osep, osepd[2] = { '\0', '\0' }; 
     
    26222603  words = (char **) mush_malloc(sizeof(char *) * BUFFER_LEN, "wordlist"); 
    26232604 
    2624   count = list2arr_ansi(words, BUFFER_LEN, args[0], sep); 
     2605  origcount = count = list2arr_ansi(words, BUFFER_LEN, args[0], sep); 
    26252606  if (count == 0) { 
    26262607    mush_free((Malloc_t) words, "wordlist"); 
     
    26332614    safe_str(words[--count], buff, bp); 
    26342615  } 
    2635   freearr(words, count); 
     2616  freearr(words, origcount); 
    26362617  mush_free((Malloc_t) words, "wordlist"); 
    26372618} 
     
    27832764    sp = tbuf2; 
    27842765    if (process_expression(buff, bp, &sp, executor, caller, enactor, 
    2785                PE_DEFAULT, PT_DEFAULT, pe_info)) 
     2766               PE_DEFAULT, PT_DEFAULT, pe_info)) { 
     2767      mush_free((Malloc_t) tbuf2, "replace_string.buff"); 
    27862768      break; 
    2787     if (*bp == (buff + BUFFER_LEN - 1) && pe_info->fun_invocations == funccount) 
     2769    } 
     2770    if (*bp == (buff + BUFFER_LEN - 1) && pe_info->fun_invocations == funccount) { 
     2771      mush_free((Malloc_t) tbuf2, "replace_string.buff"); 
    27882772      break; 
     2773    } 
    27892774    funccount = pe_info->fun_invocations; 
    27902775    oldbp = *bp; 
     
    32223207 
    32233208  /* Ansi-less regedits */ 
    3224   for (i=1 ; i < nargs - 1; i+= 2) { 
     3209  for (i = 1; i < nargs - 1; i += 2) { 
    32253210    /* If this string has ANSI, switch to using ansi only */ 
    3226     if (strchr(postbuf,TAG_START)) break; 
    3227  
    3228     memcpy(prebuf,postbuf,BUFFER_LEN); 
     3211    if (strchr(postbuf, TAG_START)) 
     3212      break; 
     3213 
     3214    memcpy(prebuf, postbuf, BUFFER_LEN); 
    32293215    prelen = strlen(prebuf); 
    32303216 
     
    32373223    r = args[i]; 
    32383224    process_expression(tbuf, &tbp, &r, executor, caller, enactor, PE_DEFAULT, 
    3239                        PT_DEFAULT, pe_info); 
     3225              PT_DEFAULT, pe_info); 
    32403226    *tbp = '\0'; 
    32413227 
    32423228    if ((re = pcre_compile(remove_markup(tbuf, &searchlen), 
    3243                            flags, &errptr, &erroffset, tables)) == NULL) { 
     3229              flags, &errptr, &erroffset, tables)) == NULL) { 
    32443230      /* Matching error. */ 
    32453231      safe_str(T("#-1 REGEXP ERROR: "), buff, bp); 
     
    32563242      study = pcre_study(re, 0, &errptr); 
    32573243      if (errptr != NULL) { 
    3258         mush_free((Malloc_t) re, "pcre"); 
    3259         safe_str(T("#-1 REGEXP ERROR: "), buff, bp); 
    3260         safe_str(errptr, buff, bp); 
    3261         free_ansi_string(orig); 
    3262         return; 
     3244   mush_free((Malloc_t) re, "pcre"); 
     3245   safe_str(T("#-1 REGEXP ERROR: "), buff, bp); 
     3246   safe_str(errptr, buff, bp); 
     3247   free_ansi_string(orig); 
     3248   return; 
    32633249      } 
    32643250      if (study != NULL) 
    3265         /* study */ 
    3266         add_check("pcre.extra"); 
     3251   /* study */ 
     3252   add_check("pcre.extra"); 
    32673253    } 
    32683254 
     
    32773263      safe_str(prebuf, postbuf, &postp); 
    32783264      mush_free((Malloc_t) re, "pcre"); 
     3265      free_ansi_string(orig); 
    32793266      if (study) 
    3280         mush_free((Malloc_t) study, "pcre.extra"); 
     3267   mush_free((Malloc_t) study, "pcre.extra"); 
    32813268      continue; 
    32823269    } 
     
    32983285      global_eval_context.re_subpatterns = subpatterns; 
    32993286      process_expression(postbuf, &postp, &obp, executor, caller, enactor, 
    3300           PE_DEFAULT | PE_DOLLAR, PT_DEFAULT, pe_info); 
     3287            PE_DEFAULT | PE_DOLLAR, PT_DEFAULT, pe_info); 
    33013288      if ((*bp == (buff + BUFFER_LEN - 1)) 
    3302           && (pe_info->fun_invocations == funccount)) 
    3303         break; 
     3289     && (pe_info->fun_invocations == funccount)) 
     3290   break; 
    33043291 
    33053292      oldbp = postp; 
     
    33103297      /* Make sure we advance at least 1 char */ 
    33113298      if (offsets[0] == match_offset) 
    3312         match_offset++; 
     3299   match_offset++; 
    33133300    } while (all && match_offset < prelen && 
    3314                   (subpatterns = pcre_exec(re, study, prebuf, prelen, 
    3315                    match_offset, 0, offsets, 99)) >= 0); 
     3301        (subpatterns = pcre_exec(re, study, prebuf, prelen, 
     3302                     match_offset, 0, offsets, 99)) >= 0); 
    33163303 
    33173304    safe_str(start, postbuf, &postp); 
     
    33363323      r = args[i]; 
    33373324      process_expression(tbuf, &tbp, &r, executor, caller, enactor, PE_DEFAULT, 
    3338                         PT_DEFAULT, pe_info); 
     3325            PT_DEFAULT, pe_info); 
    33393326      *tbp = '\0'; 
    33403327 
    33413328      if ((re = pcre_compile(remove_markup(tbuf, &searchlen), 
    3342                              flags, &errptr, &erroffset, tables)) == NULL) { 
    3343         /* Matching error. */ 
    3344