PennMUSH Community

Changeset 279

Show
Ignore:
Timestamp:
04/19/06 22:49:43 (3 years ago)
Author:
pennmush
Message:

PennMUSH 1.7.3p10 Archival

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • 1.7.3/CHANGES

    r277 r279  
    1717 
    1818========================================================================== 
     19 
     20Version 1.7.3 patchlevel 10                    November 20, 2000 
     21 
     22Major Changes: 
     23      * Improved detection of errors saving the game. If any problems  
     24        are encountered, the save is aborted, and online admins notified so 
     25        they can fix the problem before finding out about it too late. [SW]  
     26Flags: 
     27      * The INHERIT flag has been renamed TRUST, which better describes 
     28        its function. INHERIT remains as an alias. 
     29Commands: 
     30      * @chan now takes /ungag, /unhide, and /unmute as well as the 
     31        usual @chan/gag <channel>=no. By David@M*U*S*H. 
     32Minor Changes: 
     33      * money() called on a no_pay player returns the value of 
     34        MAX_PENNIES to ease softcode checks. Suggested by Oriens@Alexandria. 
     35      * Removed help and &help entries from the distributed pennmush.nws 
     36        because people will generally want to override them anyway 
     37        and we shouldn't introduce problems. Suggested by Jeff Heinen. 
     38      * safe_str and friends optimize trivial 0 and 1 letter strings. [SW] 
     39      * A version of word-based compression that's almost 8-bit clean 
     40        is now included. [SW] 
     41      * We now use stricmp and friends for strcasecmp and friends on 
     42        Win32, rather than roll our own. [SW] 
     43Fixes: 
     44      * @mail aliases couldn't be used by players who didn't have 
     45        permissions to see the alias members, which is wrong. 
     46        Fixed now. Report by Grinna@M*U*S*H. 
     47      * lnum(1) and lnum(0,0) were broken. Report by Jeff Ferrell  
     48      * Help updates. [SW] 
     49      * @set obj/notanattribute=flag now returns a 'No such attribute' error. 
     50        Reported by David@M*U*S*H. [SW] 
     51      * Help file indexing tries to detect files that aren't in the right  
     52        format. [SW] 
     53      * function restrictions were checking the wrong object. [SW]  
     54      * objmem and playermem counted eval-locks and atr-locks incorrectly.  
     55        Reported by Javin@DynamixMUSH. [SW] 
     56      * Fixes to win32 NT_TCP stuff. [NJG] 
     57      * Rare memory leak in do_page fixed by David@M*U*S*H.  
    1958 
    2059Version 1.7.3 patchlevel 9                    November 20, 2000 
  • 1.7.3/Configure

    r275 r279  
    316316d_sigcld='' 
    317317d_signalproto='' 
     318d_sigprocmask='' 
    318319d_oldsock='' 
    319320d_socket='' 
     
    356357i_niin='' 
    357358i_sysin='' 
     359i_setjmp='' 
    358360i_stddef='' 
    359361i_stdlib='' 
     
    47694771$rm -f try* 
    47704772 
     4773echo " " 
     4774: see if we have sigprocmask 
     4775if set sigprocmask val -f d_sigprocmask; eval $csym; $val; then 
     4776    echo 'sigprocmask() found.' >&4 
     4777    val="$define" 
     4778else 
     4779    echo 'sigprocmask NOT found.' >&4 
     4780    val="$undef" 
     4781fi 
     4782$cat > set.c <<'EOP' 
     4783#include <stdio.h> 
     4784#include <sys/types.h> 
     4785#include <signal.h> 
     4786main() 
     4787{ 
     4788  sigset_t mask, oldmask; 
     4789  sigprocmask(SIG_SETMASK, &mask, &oldmask); 
     4790} 
     4791EOP 
     4792if $cc $ccflags $ldflags -o set set.c $libs >/dev/null 2>&1; then 
     4793    : 
     4794else 
     4795    echo "But you don't seem to have a working sigprocmask." >&4 
     4796    val="$undef" 
     4797fi 
     4798set d_sigprocmask; eval $setvar 
     4799$rm -f set set$_o set.c 
     4800 
    47714801socketlib='' 
    47724802sockethdr='' 
     
    55475577eval $setvar 
    55485578 
     5579: see if setjmp.h can be included 
     5580set setjmp.h i_setjmp 
     5581eval $inhdr 
    55495582: see if stdarg is available 
    55505583echo " " 
     
    64776510d_sigcld='$d_sigcld' 
    64786511d_signalproto='$d_signalproto' 
     6512d_sigprocmask='$d_sigprocmask' 
    64796513d_socket='$d_socket' 
    64806514d_socklen='$d_socklen' 
     
    65346568i_memory='$i_memory' 
    65356569i_niin='$i_niin' 
     6570i_setjmp='$i_setjmp' 
    65366571i_sgtty='$i_sgtty' 
    65376572i_stdarg='$i_stdarg' 
  • 1.7.3/MANIFEST

    r277 r279  
    5858src/comp_h.c 
    5959src/comp_w.c 
     60src/comp_w8.c 
    6061src/compress.c 
    6162src/conf.c 
  • 1.7.3/Patchlevel

    r277 r279  
    11Do not edit this file. It is maintained by the official PennMUSH patches. 
    2 This is PennMUSH 1.7.3p9 
     2This is PennMUSH 1.7.3p10 
  • 1.7.3/config_h.SH

    r275 r279  
    637637#$d_signalproto CAN_PROTOTYPE_SIGNAL    /**/ 
    638638 
     639/* HAS_SIGPROCMASK: 
     640 *  This symbol, if defined, indicates that POSIX's sigprocmask() routine 
     641 *  is available. 
     642 */ 
     643#$d_sigprocmask HAS_SIGPROCMASK /**/ 
     644 
    639645/* HAS_SOCKLEN_T: 
    640646 *  If defined, this system has the socklen_t type. 
     
    736742#$i_memory I_MEMORY     /**/ 
    737743 
     744/* I_SETJMP: 
     745 *  This symbol, if defined, indicates to the C program that it can 
     746 *  include <setjmp.h> and have things work right. 
     747 */ 
     748#$i_setjmp I_SETJMP     /**/ 
     749 
    738750/* USE_TIOCNOTTY: 
    739751 *  This symbol, if defined indicate to the C program that the ioctl() 
  • 1.7.3/game/txt/hlp/penncmd.hlp

    r277 r279  
    488488   
    489489  Whenever an object besides a player is @chzoned to a zone object,  
    490   the WIZARD, ROYALTY, and INHERIT flags will be reset, as will all 
     490  the WIZARD, ROYALTY, and TRUST flags will be reset, as will all 
    491491  @power's (for security purposes). For similar reasons, it is strongly  
    492492  recommended that you do not @chzone admin- or wizard-owned objects to  
     
    33673367  The person using the object must pass its uselock; no inheritance check 
    33683368  is necessary. This is may be done remotely, by using a dbref number; 
    3369   it provides an easy way for non-INHERIT objects to perform commands on 
    3370   INHERIT objects. 
     3369  it provides an easy way for non-TRUST objects to perform commands on 
     3370  TRUST objects. 
    33713371 
    33723372  If the person fails to pass the object's uselock, the object's 
  • 1.7.3/game/txt/hlp/pennflag.hlp

    r273 r279  
    4040  A - Abode, Ansi       C - Chown_Ok, Color     D - Dark 
    4141  E - Exit (type)       F - Floating, Fixed     G - Going 
    42   H - Haven             I - Inherit             J - Jump_Ok, Judge 
     42  H - Haven             I - Trust/Inherit       J - Jump_Ok, Judge 
    4343  L - Link_Ok           M - Monitor             N - Nospoof, No_Tel, No_Leave 
    4444  O - Opaque            P - Player (type)       Q - Quiet 
     
    308308See also: @haven, kill 
    309309& INHERIT 
    310   Flag:  INHERIT  (all types) 
    311  
    312   Inherit is a security flag used to prevent objects without authorization 
     310& TRUST 
     311  Flag:  TRUST  (all types) 
     312 
     313  TRUST is a security flag used to prevent objects without authorization 
    313314  from using @force, @set, and @trigger on other objects. 
    314   Authorization is successful if: 
    315   
    316      1. The enactor is WIZARD. 
    317      2. The enactor's owner is INHERIT. 
    318      2. The enactor is INHERIT. 
    319      3. The target is not INHERIT. 
    320   
    321   Only INHERIT or WIZARD objects may force their owners. Players can 
    322   always @force, @set, and @trigger their objects.  
    323   
    324   Read "help Inherit2" for more. 
    325   
     315  Authorization is successful if any of these are true: 
     316  
     317     1. The enactor is WIZARD ("wizards control all"). 
     318     2. The enactor's owner is TRUST ("the player trusts all their objects"). 
     319     3. The enactor is TRUST ("this object is trusted"). 
     320     4. The target is not TRUST ("this object isn't trusted"). 
     321 
     322  That is, if a non-wizard player is set TRUST, all of their objects 
     323  may act on each other (case 2). Otherwise, only TRUST objects may act 
     324  on TRUST objects (case 3) but any of the player's object may act on 
     325  non-TRUST objects (case 4). 
     326 
     327  Only TRUST or WIZARD objects may force their owners.  
     328  Players can always @force, @set, and @trigger their objects.  
     329 
     330  This flag used to be called INHERIT, and INHERIT is still an alias 
     331  for it, but TRUST better describes its action. 
     332  
     333  Read "help trust2" for more. 
     334& TRUST2 
    326335& INHERIT2 
    327336  
    328337  Authorization is only denied if the enactor is neither a player nor 
    329   INHERIT, and the target is WIZARD, INHERIT, or is a player. 
    330   The INHERIT protection against @trigger may be overridden by setting 
     338  TRUST, and the target is WIZARD, TRUST, or is a player. 
     339 
     340  The TRUST protection against @trigger may be overridden by setting 
    331341  the target object LINK_OK. 
     342 
    332343  Objects which are WIZARD are not subject to any special criterion, 
    333   although they are automatically considered to be INHERIT. 
     344  although they are automatically considered to be TRUST. 
    334345  The normal criteria for object control still apply. 
    335346  
    336   For zoned objects, the INHERIT flag protects against an object from 
     347  For zoned objects, the TRUST flag protects against an object from 
    337348  being controlled by anything not owned by its owner. This prevents 
    338349  someone who controls a zone from doing things like @forcing an 
    339   INHERIT object to @force its owner. 
     350  TRUST object to @force its owner. 
    340351& JUDGE 
    341352& JURY_OK 
     
    361372 
    362373  If a room or object is LINK_OK, anyone can link exits to it (but  
    363   still not from it). Also, LINK_OK overrides the INHERIT protection 
     374  still not from it). Also, LINK_OK overrides the TRUST protection 
    364375  against @trigger (although not @force or @set). This also allows  
    365376  others to @parent their objects to the thing set LINK_OK. 
    366377 
    367 See @link, INHERIT, @parent, PARENTS 
     378See @link, TRUST, @parent, PARENTS 
    368379& MONITOR 
    369380  Flag:  MONITOR  (players) 
  • 1.7.3/game/txt/hlp/pennfunc.hlp

    r277 r279  
    21412141& R() 
    21422142& R-FUNCTION 
    2143   r(<number>) 
     2143  r(<register>) 
    21442144   
    21452145  The r() function is used to access "local registers", and returns 
    2146   the contents of the specified register. There are ten such registers, 
    2147   numbered 0 through 9
     2146  the contents of the specified register. There are 36 such registers, 
     2147  numbered 0 through 9, and A through Z
    21482148  
    21492149  The '%qN' percent-substitution can also be used to access these local 
    2150   registers, where N is register <number> needed. 
     2150  registers, where N is register <register> needed. 
    21512151   
    21522152  See "help SETQ()" for details about registers. 
     
    24102410& SETQ() 
    24112411& SETR() 
    2412   setq(<number>,<string>) 
    2413   setr(<number>,<string>) 
     2412  setq(<register>,<string>) 
     2413  setr(<register>,<string>) 
    24142414   
    24152415  The setq() and setr() functions are used to copy strings into local 
     
    24172417  function.  setr() returns the value stored. 
    24182418   
    2419   There are ten local registers, numbered 0 through 9. They are cleared 
    2420   at the start of each new queue cycle (i.e. whenever a new command is 
    2421   evaluated). They are most useful for storing complex function evaluations 
    2422   which are used repeatedly within a single command. 
     2419  There are thirtysix local registers, numbered 0 through 9 and A through Z. 
     2420  They are cleared at the start of each new queue cycle (i.e. whenever 
     2421  a new command is evaluated). They are most useful for storing 
     2422  complex function evaluations which are used repeatedly within a 
     2423  single command. 
    24232424  
    24242425  Registers set via setq() or setr() can be accessed via the r() function,  
     
    24552456  time of the branch, so the code: 
    24562457     
    2457   say setq(0,foo)%q0; @wait 0=say %q0; say setq(0,bar)%q0 
     2458  say setr(a,foo); @wait 0=say %qa; say setr(a,bar) 
    24582459     
    24592460  produces the following when executed by an object: 
  • 1.7.3/game/txt/hlp/penntop.hlp

    r277 r279  
    308308  4. If V is Royalty, O must be Royalty 
    309309  5. If V and O are owned by the same player: 
    310      5a. If V is not inherit, O controls V 
    311      5b. If V is inherit, O must be inherit or the player must be inherit 
    312   6. If V is on a zone, and isn't a player and isn't inherit
     310     5a. If V is not TRUST, O controls V 
     311     5b. If V is TRUST, O must be TRUST or the player must be TRUST 
     312  6. If V is on a zone, and isn't a player and isn't TRUST
    313313     O controls V if O passes the zone-lock of the zone. 
    314314  7. If V is owned by a ZONE player, and V isn't a player, 
     
    317317  There's also one special case: anyone can @link an unlinked exit, 
    318318 
    319 See also: controls(), INHERIT, ZONES, ZONE MASTERS 
     319See also: controls(), TRUST, ZONES, ZONE MASTERS 
    320320& COSTS 
    321321  These are usually: 
     
    16491649  to it. This, however, does not refund the original creator's money or 
    16501650  quota, as does normal @chown. Using a Zone Master instead of a ZMO  
    1651   enables a higher degree of security within the zone, and allows INHERI
     1651  enables a higher degree of security within the zone, and allows TRUS
    16521652  objects to be placed in the zone, since all objects within the zone have 
    16531653  the same owner. $commands are not, however, inherited off the Zone Master. 
  • 1.7.3/game/txt/hlp/pennvers.hlp

    r277 r279  
    11& changes 
    2 & 1.7.3p9 
     2& 1.7.3p10 
    33This is a list of changes in this patchlevel which are probably of 
    44interest to players. More information about new commands and functions 
     
    1010be read in 'help patchlevels'. 
    1111 
     12Version 1.7.3 patchlevel 10                    November 20, 2000 
     13 
     14Major Changes: 
     15      * Improved detection of errors saving the game. If any problems  
     16        are encountered, the save is aborted, and online admins notified so 
     17        they can fix the problem before finding out about it too late. [SW]  
     18Flags: 
     19      * The INHERIT flag has been renamed TRUST, which better describes 
     20        its function. INHERIT remains as an alias. 
     21Commands: 
     22      * @chan now takes /ungag, /unhide, and /unmute as well as the 
     23        usual @chan/gag <channel>=no. By David@M*U*S*H. 
     24Minor Changes: 
     25      * money() called on a no_pay player returns the value of 
     26        MAX_PENNIES to ease softcode checks. Suggested by Oriens@Alexandria. 
     27      * Removed help and &help entries from the distributed pennmush.nws 
     28        because people will generally want to override them anyway 
     29        and we shouldn't introduce problems. Suggested by Jeff Heinen. 
     30      * safe_str and friends optimize trivial 0 and 1 letter strings. [SW] 
     31      * A version of word-based compression that's almost 8-bit clean 
     32        is now included. [SW] 
     33      * We now use stricmp and friends for strcasecmp and friends on 
     34        Win32, rather than roll our own. [SW] 
     35Fixes: 
     36      * @mail aliases couldn't be used by players who didn't have 
     37        permissions to see the alias members, which is wrong. 
     38        Fixed now. Report by Grinna@M*U*S*H. 
     39      * lnum(1) and lnum(0,0) were broken. Report by Jeff Ferrell  
     40      * Help updates. [SW] 
     41      * @set obj/notanattribute=flag now returns a 'No such attribute' error. 
     42        Reported by David@M*U*S*H. [SW] 
     43      * Help file indexing tries to detect files that aren't in the right  
     44        format. [SW] 
     45      * function restrictions were checking the wrong object. [SW]  
     46      * objmem and playermem counted eval-locks and atr-locks incorrectly.  
     47        Reported by Javin@DynamixMUSH. [SW] 
     48      * Fixes to win32 NT_TCP stuff. [NJG] 
     49      * Rare memory leak in do_page fixed by David@M*U*S*H.  
     50 
     51& 1.7.3p9 
    1252Version 1.7.3 patchlevel 9                    November 20, 2000 
    1353 
     
    41644204 
    41654205& patchlevels 
    4166 1.7.3: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 
     42061.7.3: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 
    416742071.7.2: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 
    41684208       19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 
  • 1.7.3/game/txt/nws/pennmush.nws

    r261 r279  
    1 & help 
    2   
    3 --------------------------- MUSH News Topics ------------------------------ 
    4 --------------------------------------------------------------------------- 
    5  
    61& code 
    72See 'help code' 
     
    94& changes 
    105See 'help changes' 
    11 & &help 
    12 This is the ANEWS index. 
  • 1.7.3/hdrs/attrib.h

    r277 r279  
    2020extern void do_attribute_info _((dbref player, char *name)); 
    2121extern void do_list_attribs _((dbref player, int lc)); 
     22extern char *list_attribs _((int lc)); 
    2223 
    2324/* From attrib.c */ 
  • 1.7.3/hdrs/command.h

    r269 r279  
    213213_((dbref player, dbref cause, char *string, int fromport)); 
    214214extern void do_list_commands _((dbref player, int lc)); 
     215extern char *list_commands _((int lc)); 
    215216extern int command_check_byname _((dbref player, const char *name)); 
    216217extern int restrict_command _((const char *name, const char *restriction)); 
  • 1.7.3/hdrs/externs.h

    r277 r279  
    2424#include "confmagic.h" 
    2525#ifndef HAS_STRCASECMP 
     26#ifdef WIN32 
     27#define strcasemp(s1,s2) _stricmp((s1), (s2)) 
     28#define strncasecmp(s1,s2,n) _strnicmp((s1), (s2), (n)) 
     29#else 
    2630extern int strcasecmp _((const char *s1, const char *s2)); 
    2731extern int strncasecmp _((const char *s1, const char *s2, Size_t n)); 
     32#endif 
    2833#endif 
    2934 
  • 1.7.3/hdrs/function.h

    r277 r279  
    7878extern void do_function_restore _((dbref player, const char *name)); 
    7979extern void do_list_functions _((dbref player, int lc)); 
     80extern char *list_functions _((int lc)); 
    8081extern void do_function _((dbref player, char *name, char **argv)); 
    8182extern void do_function_toggle _((dbref player, char *name, int toggle)); 
  • 1.7.3/hdrs/switches.h

    r277 r279  
    114114#define SWITCH_UNCLEAR 114 
    115115#define SWITCH_UNFOLDER 115 
    116 #define SWITCH_UNTAG 116 
    117 #define SWITCH_URGENT 117 
    118 #define SWITCH_USEFLAG 118 
    119 #define SWITCH_WHAT 119 
    120 #define SWITCH_WIPE 120 
    121 #define SWITCH_WIZ 121 
    122 #define SWITCH_WIZARD 122 
    123 #define SWITCH_YES 123 
    124 #define SWITCH_ZONE 124 
     116#define SWITCH_UNGAG 116 
     117#define SWITCH_UNHIDE 117 
     118#define SWITCH_UNMUTE 118 
     119#define SWITCH_UNTAG 119 
     120#define SWITCH_URGENT 120 
     121#define SWITCH_USEFLAG 121 
     122#define SWITCH_WHAT 122 
     123#define SWITCH_WIPE 123 
     124#define SWITCH_WIZ 124 
     125#define SWITCH_WIZARD 125 
     126#define SWITCH_YES 126 
     127#define SWITCH_ZONE 127 
  • 1.7.3/hdrs/version.h

    r277 r279  
    1 #define VERSION "PennMUSH version 1.7.3 patchlevel 9 [11/20/2000]" 
    2 #define SHORTVN "PennMUSH 1.7.3p9
     1#define VERSION "PennMUSH version 1.7.3 patchlevel 10 [11/20/2000]" 
     2#define SHORTVN "PennMUSH 1.7.3p10
  • 1.7.3/options.h.dist

    r277 r279  
    8080 * 1 - the default Huffman compression which has been in use since 
    8181 *     pl10. In theory, this should be the best compression, 
    82  *     possibly at the cost of some speed. Sometimes has trouble 
    83  *     on linux systems for some reason. 
     82 *     possibly at the cost of some speed. It is also 8-bit clean, 
     83 *     and thus suitable for locales that use extended character sets. 
     84 *     Sometimes has trouble on some linux systems for some reason. 
    8485 * 2 - the bigram compression from pl9 and earlier (but autotuned) 
    8586 *     This should be intermediate in compression and speed, and 
     
    9293 *     is worse than Huffman for small dbs (<1.5Mb of text), but 
    9394 *     better for larger dbs. Win32 systems must use this. 
     95 * 4 - Raevnos's almost 8-bit clean version of the word-based algorithm. 
     96 *     Prefer 3 unless you need extended characters. This algorithm 
     97 *     can encode all characters except 0x06. 
    9498 * 0 - No compression at all. Very fast, but your db in memory 
    9599 *     will be big - at least as large as your on-disk db. 
    96100 *     Possibly suitable for the building stages of a small MUSH. 
     101 *     This should be 8-bit clean, too. 
    97102 * You can change this at any time, with no worries. It only affects 
    98103 * the in-memory compression of attribute/mail text, not the disk 
    99  * db compression. Recommend to keep it at 1. 
     104 * db compression. Recommend to keep it at 1. When in doubt, try them 
     105 * all, and chekc @uptime's memory usage stats for the most efficient 
     106 * choice among those that are stable for you. 
    100107 */ 
    101108#define COMPRESSION_TYPE 1 
  • 1.7.3/src/SWITCHES

    r277 r279  
    113113TRACE 
    114114UNCLEAR 
     115UNHIDE 
     116UNGAG 
    115117UNFOLDER 
     118UNMUTE 
    116119UNTAG 
    117120URGENT 
  • 1.7.3/src/atr_tab.c

    r273 r279  
    321321    int lc; 
    322322{ 
     323  notify(player, list_attribs(lc)); 
     324} 
     325 
     326char * 
     327list_attribs(lc) 
     328    int lc; 
     329{ 
    323330  ATTR *ap; 
    324331  char *ptrs[BUFFER_LEN / 2]; 
    325   char buff[BUFFER_LEN]; 
     332  static char buff[BUFFER_LEN]; 
    326333  char *bp; 
    327334  int nptrs = 0, i; 
     
    347354  } 
    348355  *bp = '\0'; 
    349   notify(player, buff); 
    350356  hashfree(&temp); 
    351 
     357  return buff; 
     358
  • 1.7.3/src/boolexp.c

    r275 r279  
    203203  case BOOLEXP_ATR: 
    204204  case BOOLEXP_EVAL: 
    205     return sizeof(struct boolexp) + sizeof(struct boolatr) - BUFFER_LEN
     205    return sizeof(struct boolexp) + sizeof(struct boolatr)
    206206      strlen(b->atr_lock->name) + 1 + 
    207207#ifdef macintosh 
  • 1.7.3/src/bsd.c

    r277 r279  
    33/* Windows NT users may uncomment this define to get the native network i/o 
    44 * thread model instead of the bsd socket layer, for vastly better 
    5  * performance. Doesn't work on Win 95/98. By Nick Gammon  
     5 * performance. Doesn't work on Win 95/98. By Nick Gammon 
    66 */ 
    77/* #define NT_TCP */ 
     
    9393#endif 
    9494#endif 
    95  
     95#ifdef I_SETJMP 
     96#include <setjmp.h> 
     97#endif 
    9698 
    9799#include "conf.h" 
     
    395397  /* Unlimit file descriptors. */ 
    396398  /* Ultrix 4.4 and others may have getrlimit but may not be able to 
    397    * change number of file descriptors  
     399   * change number of file descriptors 
    398400   */ 
    399401#ifdef RLIMIT_NOFILE 
     
    421423 
    422424#ifdef NT_TCP 
    423 BOOL 
    424 IsValidAddress(const void *lp, UINT nBytes, BOOL bReadWrite) 
     425BOOL IsValidAddress(const void *lp, UINT nBytes, BOOL bReadWrite) 
    425426{ 
    426427  return (lp != NULL && 
     
    557558 
    558559  /* If we have setlocale, call it to set locale info 
    559    * from environment variables  
     560   * from environment variables 
    560561   */ 
    561562#ifdef HAS_SETLOCALE 
     
    798799/*#ifdef macintosh 
    799800  int   i; 
    800    
     801 
    801802  for ( i = 0; i < NSIG; i++ ) 
    802803     signal( i, SIG_IGN ); 
     
    20742075  *bp = '\0'; 
    20752076  if (Forbidden_Site(tbuf1) || Forbidden_Site(tbuf2)) { 
    2076     do_log(LT_CONN, 0, 0, T("[%d/%s/%s] Refused connection (remote port %s)"), 
    2077        newsock, tbuf1, tbuf2, hi->port); 
     2077    do_log(LT_CONN, 0, 0, "[%d/%s/%s] %s (%s %s)", 
     2078       newsock, tbuf1, tbuf2, T("Refused connection"), T("remote port"), 
     2079       hi ? hi->port : T("(unknown)")); 
    20782080    shutdown(newsock, 2); 
    20792081    closesocket(newsock); 
     
    40284030    /* A brand new player created. */ 
    40294031    sprintf(tbuf1, T("%s created."), Name(player)); 
    4030     flag_broadcast(0, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4032    flag_broadcast(0, PLAYER_MONITOR, "%s %s", T("GAME:"), tbuf1); 
    40314033    if (Suspect(player)) 
    40324034      flag_broadcast(WIZARD, 0, T("GAME: Suspect %s created."), Name(player)); 
     
    40514053  if (Dark(player)) { 
    40524054#ifdef ROYALTY_FLAG 
    4053     flag_broadcast(WIZARD | ROYALTY, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4055    flag_broadcast(WIZARD | ROYALTY, PLAYER_MONITOR, "%s %s", T("GAME:"), 
     4056           tbuf1); 
    40544057#else 
    4055     flag_broadcast(WIZARD, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4058    flag_broadcast(WIZARD, PLAYER_MONITOR, "%s %s", T("GAME:"), tbuf1); 
    40564059#endif 
    40574060  } else 
    4058     flag_broadcast(0, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4061    flag_broadcast(0, PLAYER_MONITOR, "%s %s", T("GAME:"), tbuf1); 
    40594062 
    40604063  /* tell players on a channel when someone connects */ 
     
    42294232  if (Dark(player)) { 
    42304233#ifdef ROYALTY_FLAG 
    4231     flag_broadcast(WIZARD | ROYALTY, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4234    flag_broadcast(WIZARD | ROYALTY, PLAYER_MONITOR, "%s %s", T("GAME:"), 
     4235           tbuf1); 
    42324236#else 
    4233     flag_broadcast(WIZARD, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4237    flag_broadcast(WIZARD, PLAYER_MONITOR, "%s %s", T("GAME:"), tbuf1); 
    42344238#endif 
    42354239  } else 
    4236     flag_broadcast(0, PLAYER_MONITOR, "GAME: %s", tbuf1); 
     4240    flag_broadcast(0, PLAYER_MONITOR, "%s %s", T("GAME:"), tbuf1); 
    42374241 
    42384242  /* tell players on channel that someone's left */ 
     
    44514455{ 
    44524456  /* Return the status of the pueblo flag on the least idle descriptor we 
    4453    * find that matches the player's dbref.  
     4457   * find that matches the player's dbref. 
    44544458   */ 
    44554459  DESC *d; 
     
    45594563FUNCTION(fun_ports) 
    45604564{ 
    4561   /* returns a list of the network descriptors that a player is  
     4565  /* returns a list of the network descriptors that a player is 
    45624566   * connected to (wizard-only) 
    45634567   */ 
     
    47354739 
    47364740  nac.u = ChanUsers(channel); 
    4737   nac.checkquiet = (flags & 0x1) ? 1 : 0; 
     4741  nac.checkquiet = (flags & CU_QUIET) ? 1 : 0; 
    47384742  notify_anything(player, na_channel, &nac, 
    4739           (flags & 0x2) ? ns_esnotify : NULL, 0, tbuf1); 
     4743          (flags & CU_HIDE) ? ns_esnotify : NULL, 0, tbuf1); 
    47404744} 
    47414745 
     
    47974801 
    47984802  /* Feh. We need to do some sort of privilege checking, so that 
    4799    * if mortals can't do '@channel/who wizard', they can't do  
     4803   * if mortals can't do '@channel/who wizard', they can't do 
    48004804   * 'think cwho(wizard)' either. The first approach that comes to 
    48014805   * mind is the following: 
     
    50325036 * * dump_reboot_db: Dumps descriptor_list to REBOOTFILE 
    50335037 */ 
     5038#ifdef I_SETJMP 
     5039extern jmp_buf db_err; 
     5040#endif 
    50345041void 
    50355042dump_reboot_db() 
     
    50385045  DESC *d; 
    50395046 
    5040   f = fopen(REBOOTFILE, "w"); 
    5041  
    5042   /* This shouldn't happen */ 
    5043   if (!f) { 
     5047#ifdef I_SETJMP 
     5048  if (setjmp(db_err)) { 
    50445049    flag_broadcast(0, 0, T("GAME: Error writing reboot database!")); 
    50455050    exit(0); 
    5046   } 
    5047   putref(f, sock); 
    5048   putref(f, maxd); 
    5049  
    5050   /* First, iterate through all descriptors to get to the end  
    5051    * we do this so the descriptor_list isn't reversed on reboot  
    5052    */ 
    5053   for (d = descriptor_list; d && d->next; d = d->next) ; 
    5054  
    5055   /* Second, we iterate backwards from the end of descriptor_list 
    5056    * which is now in the d variable. 
    5057    */ 
    5058   for (; d != NULL; d = d->prev) { 
    5059  
    5060     putref(f, d->descriptor); 
    5061     putref(f, d->connected_at); 
    5062     putref(f, d->hide); 
    5063     putref(f, d->cmds); 
    5064     if (GoodObject(d->player)) 
    5065       putref(f, d->player); 
    5066     else 
    5067       putref(f, -1); 
    5068     putref(f, d->last_time); 
    5069     if (d->output_prefix) 
    5070       putstring(f, d->output_prefix); 
    5071     else 
    5072       putstring(f, "__NONE__"); 
    5073     if (d->output_suffix) 
    5074       putstring(f, d->output_suffix); 
    5075     else 
    5076       putstring(f, "__NONE__"); 
    5077     putstring(f, d->addr); 
    5078     putstring(f, d->ip); 
    5079     putstring(f, d->doing); 
    5080     putref(f, d->pueblo); 
    5081   }             /* for loop */ 
    5082  
    5083   putref(f, 0); 
    5084   putstring(f, poll_msg); 
    5085   putref(f, first_start_time); 
    5086   putref(f, reboot_count); 
    5087   fclose(f); 
     5051  } else { 
     5052#endif 
     5053 
     5054 
     5055    f = fopen(REBOOTFILE, "w"); 
     5056 
     5057    /* This shouldn't happen */ 
     5058    if (!f) { 
     5059      flag_broadcast(0, 0, T("GAME: Error writing reboot database!")); 
     5060      exit(0); 
     5061    } 
     5062    putref(f, sock); 
     5063    putref(f, maxd); 
     5064 
     5065    /* First, iterate through all descriptors to get to the end 
     5066     * we do this so the descriptor_list isn't reversed on reboot 
     5067     */ 
     5068    for (d = descriptor_list; d && d->next; d = d->next) ; 
     5069 
     5070    /* Second, we iterate backwards from the end of descriptor_list 
     5071     * which is now in the d variable. 
     5072     */ 
     5073    for (; d != NULL; d = d->prev) { 
     5074 
     5075      putref(f, d->descriptor); 
     5076      putref(f, d->connected_at); 
     5077      putref(f, d->hide); 
     5078      putref(f, d->cmds); 
     5079      if (GoodObject(d->player)) 
     5080    putref(f, d->player); 
     5081      else 
     5082    putref(f, -1); 
     5083      putref(f, d->last_time); 
     5084      if (d->output_prefix) 
     5085    putstring(f, d->output_prefix); 
     5086      else 
     5087    putstring(f, "__NONE__"); 
     5088      if (d->output_suffix) 
     5089    putstring(f, d->output_suffix); 
     5090      else 
     5091    putstring(f, "__NONE__"); 
     5092      putstring(f, d->addr); 
     5093      putstring(f, d->ip); 
     5094      putstring(f, d->doing); 
     5095      putref(f, d->pueblo); 
     5096    }               /* for loop */ 
     5097 
     5098    putref(f, 0); 
     5099    putstring(f, poll_msg); 
     5100    putref(f, first_start_time); 
     5101    putref(f, reboot_count); 
     5102    fclose(f); 
     5103#ifdef I_SETJMP 
     5104  } 
     5105#endif 
    50885106} 
    50895107 
     
    51825200/* Thread to listen on MUD port - for Windows NT */ 
    51835201/* --------------------------------------------------------------------------- */ 
    5184  
    51855202void __cdecl 
    51865203MUDListenThread(void *pVoid) 
     
    51895206 
    51905207  SOCKET socketClient; 
    5191   SOCKADDR_IN SockAddr; 
    5192   int nLen; 
     5208  union sockaddr_u addr; 
     5209  int nLen, addr_len; 
     5210  struct hostname_info *hi; 
    51935211/*  int     i; */ 
    51945212  BOOL b; 
     
    52065224    /* Block on accept() */ 
    52075225    nLen = sizeof(SOCKADDR_IN); 
    5208     socketClient = accept(MUDListenSocket, (LPSOCKADDR) & SockAddr, &nLen); 
     5226    socketClient = accept(MUDListenSocket, (LPSOCKADDR) & addr, &nLen); 
    52095227 
    52105228    if (socketClient == INVALID_SOCKET) { 
     
    52175235 
    52185236    bp = tbuf2; 
    5219     safe_str((char *) ip_convert(SockAddr.sin_addr), tbuf2, &bp); 
     5237    safe_str((const char *) ip_convert(&addr.addr, nLen), tbuf2, &bp); 
    52205238    *bp = '\0'; 
    52215239    bp = tbuf1; 
    5222     safe_str((char *) hostname_convert(SockAddr.sin_addr), tbuf1, &bp); 
     5240    addr_len = sizeof(addr); 
     5241    hi = hostname_convert(&addr.addr, addr_len); 
     5242    safe_str(hi ? hi->hostname : "", tbuf1, &bp); 
    52235243    *bp = '\0'; 
    52245244    if (Forbidden_Site(tbuf1) || Forbidden_Site(tbuf2)) { 
    5225       do_log(LT_CONN, 0, 0, T("[%d/%s] Refused connection (remote port %d)"), 
    5226          socketClient, tbuf1, ntohs(SockAddr.sin_port)); 
     5245      do_log(LT_CONN, 0, 0, T("[%d/%s] Refused connection (remote port %s)"), 
     5246         socketClient, tbuf1, hi->port); 
    52275247      shutdown(socketClient, 2); 
    52285248      closesocket(socketClient); 
     
    52485268      continue; 
    52495269    } 
    5250 /* welcome the user - we can't do this until the completion port is created */ 
     5270/* welcome the user - we can't do this until the completion port is created 
     5271*/ 
    52515272 
    52525273    welcome_user(d); 
  • 1.7.3/src/cmds.c

    r277 r279  
    122122  else if (SW_ISSET(sw, SWITCH_QUIET)) 
    123123    do_chan_admin(player, arg_left, arg_right, 4); 
     124  else if (SW_ISSET(sw, SWITCH_NOISY)) 
     125    do_chan_admin(player, arg_left, "n", 4); 
    124126  else if (SW_ISSET(sw, SWITCH_DECOMPILE)) 
    125127    do_chan_decompile(player, arg_left, SW_ISSET(sw, SWITCH_BRIEF)); 
     
    134136  else if (SW_ISSET(sw, SWITCH_MUTE)) 
    135137    do_chan_user_flags(player, arg_left, arg_right, 0, 0); 
     138  else if (SW_ISSET(sw, SWITCH_UNMUTE)) 
     139    do_chan_user_flags(player, arg_left, "n", 0, 0); 
    136140  else if (SW_ISSET(sw, SWITCH_HIDE)) 
    137141    do_chan_user_flags(player, arg_left, arg_right, 1, 0); 
     142  else if (SW_ISSET(sw, SWITCH_UNHIDE)) 
     143    do_chan_user_flags(player, arg_left, "n", 1, 0); 
    138144  else if (SW_ISSET(sw, SWITCH_GAG)) 
    139145    do_chan_user_flags(player, arg_left, arg_right, 2, 0); 
     146  else if (SW_ISSET(sw, SWITCH_UNGAG)) 
     147    do_chan_user_flags(player, arg_left, "n", 2, 0); 
    140148  else if (SW_ISSET(sw, SWITCH_WHAT)) 
    141149    do_chan_what(player, arg_left); 
  • 1.7.3/src/command.c

    r277 r279  
    7070   CMD_T_ANY | CMD_T_EQSPLIT | CMD_T_NOGAGGED, 0, 0, 0}, 
    7171  {"@CHANNEL", 
    72    "LIST ADD DELETE RENAME NAME PRIVS QUIET DECOMPILE DESC CHOWN WIPE MUTE GAG HIDE WHAT TITLE BRIEF", 
     72   "LIST ADD DELETE RENAME NAME PRIVS QUIET NOISY DECOMPILE DESC CHOWN WIPE MUTE UNMUTE GAG UNGAG HIDE UNHIDE WHAT TITLE BRIEF", 
    7373   cmd_channel, 
    7474   CMD_T_ANY | CMD_T_SWITCHES | CMD_T_EQSPLIT | CMD_T_NOGAGGED, 0, 0, 0}, 
     
    11841184    int lc; 
    11851185{ 
     1186  notify(player, list_commands(lc)); 
     1187} 
     1188 
     1189char * 
     1190list_commands(lc) 
     1191    int lc;