Changeset 1267
- Timestamp:
- 09/14/08 04:37:38 (3 months ago)
- Files:
-
- 1.8.3/branches/devel/hdrs/bufferq.h (modified) (1 diff)
- 1.8.3/branches/devel/src/Makefile.in (modified) (1 diff)
- 1.8.3/branches/devel/src/bsd.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/cque.c (modified) (1 diff)
- 1.8.3/branches/devel/src/csrimalloc.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/extchat.c (modified) (8 diffs)
- 1.8.3/branches/devel/src/fundb.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/funmath.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/game.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/info_master.c (modified) (3 diffs)
- 1.8.3/branches/devel/src/intmap.c (modified) (12 diffs)
- 1.8.3/branches/devel/src/notify.c (modified) (1 diff)
- 1.8.3/branches/devel/src/parse.c (modified) (1 diff)
- 1.8.3/branches/devel/src/pcre.c (modified) (4 diffs)
- 1.8.3/branches/devel/src/set.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/ssl_slave.c (modified) (13 diffs)
- 1.8.3/branches/devel/src/tables.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
1.8.3/branches/devel/hdrs/bufferq.h
r1231 r1267 28 28 BUFFERQ *reallocate_bufferq(BUFFERQ *bq, int lines); 29 29 void free_bufferq(BUFFERQ *bq); 30 void add_to_bufferq(BUFFERQ *bq, int type, dbref player, 31 const char *msg); 30 void add_to_bufferq(BUFFERQ *bq, int type, dbref player, const char *msg); 32 31 char *iter_bufferq(BUFFERQ *bq, char **p, dbref *player, int *type, 33 32 time_t * timestamp); 1.8.3/branches/devel/src/Makefile.in
r1208 r1267 148 148 (set +e; for file in *.dst *.c ../hdrs/*.h ; do echo $$file; \ 149 149 @INDENT@ -npro -kr -ci2 -ss -psl -ip4 -i2 -cs -l80 -lc75 -nut \ 150 -T _Bool -T accent_info -T acsflag -T aig_func -T ALIST \ 151 -T ansi_data -T ansi_string -T atr_err -T ATRALIAS -T ATTR \ 152 -T BOOL -T boolexp -T boolexp_type -T BQUE -T branch_chain \ 153 -T BUFFERQ -T bvm_opcode -T BYTE -T CHAN -T CHANLIST -T CHANUSER \ 154 -T chunk_reference_t -T CNode -T COMLIST -T command_func \ 155 -T COMMAND_INFO -T comp_func -T compile_data -T COMSORTSTRUC \ 156 -T config_func -T CType -T dbref -T Debug_Info -T DESC \ 157 -T dfa_match_data -T eptrblock -T EVAL_CONTEXT -T FBLOCK \ 158 -T fd_type -T FLAG -T FLAG_ALIAS -T FLAGSPACE -T folder_array \ 159 -T Free_t -T FUN -T function_func -T FUNTAB -T GLOBALTAB \ 160 -T hash_func -T HASHENT -T HASHTAB -T heapframe -T help_file \ 161 -T help_indx -T ident_t -T imaxdiv_t -T IVAL -T list_type_list \ 162 -T lock_list -T lock_type -T LOCKMSGINFO -T LONG -T ltype -T MAIL \ 163 -T mail_flag -T makerecord -T Malloc_t -T markup_information \ 164 -T match_data -T MATH -T MEM -T na_lookup -T NVAL \ 165 -T object_flag_type -T OPTTAB -T pcre_study_data -T pcre_uint16 \ 166 -T pcre_uint32 -T PE_Info -T PENNCONF -T PENNCONFGROUP -T Port_t \ 167 -T PRIV -T privbits -T PTAB -T ptab_entry -T qsort_func \ 168 -T real_pcre -T recursion_info -T Region -T RegionHeader -T s_rec \ 169 -T SHS_INFO -T slab -T sqlplatform -T StrNode -T StrTree \ 170 -T switch_mask -T SWITCH_VALUE -T tcheck -T tlist \ 171 -T ucp_type_table -T UIVAL -T uschar -T UsedAttr -T USERFN_ENTRY \ 172 -T WAIT_TYPE -T warn_type -T Word \ 150 -T accent_info -T acsflag -T aig_func -T ALIST -T ansi_data \ 151 -T ansi_string -T atr_err -T ATRALIAS -T ATTR -T BOOL -T boolexp \ 152 -T boolexp_type -T BQUE -T branch_chain -T BUFFERQ -T bvm_opcode \ 153 -T BYTE -T CDESC -T CHAN -T CHANLIST -T CHANUSER \ 154 -T chunk_reference_t -T CNode -T COMLIST -T command_func \ 155 -T COMMAND_INFO -T comp_func -T compile_data -T COMSORTSTRUC \ 156 -T config_func -T CType -T dbref -T Debug_Info -T DESC \ 157 -T dfa_match_data -T eptrblock -T EVAL_CONTEXT -T FBLOCK \ 158 -T fd_type -T FLAG -T FLAG_ALIAS -T FLAGSPACE -T folder_array \ 159 -T FUN -T function_func -T FUNTAB -T GLOBALTAB -T hash_func \ 160 -T HASHENT -T HASHTAB -T heapframe -T help_file -T help_indx \ 161 -T ident_t -T im_key -T imaxdiv_t -T intmap -T IVAL \ 162 -T list_type_list -T lock_list -T lock_type -T LOCKMSGINFO \ 163 -T LONG -T ltype -T MAIL -T mail_flag -T makerecord \ 164 -T markup_information -T match_data -T MATH -T MEM -T na_lookup \ 165 -T NVAL -T object_flag_type -T OPTTAB -T patricia \ 166 -T pcre_study_data -T pcre_uint16 -T pcre_uint32 -T PE_Info \ 167 -T PENNCONF -T PENNCONFGROUP -T Port_t -T PRIV -T privbits \ 168 -T PTAB -T ptab_entry -T qsort_func -T real_pcre \ 169 -T recursion_info -T Region -T RegionHeader -T s_rec -T SHS_INFO \ 170 -T slab -T sqlplatform -T STFunc -T StrNode -T StrTree \ 171 -T switch_mask -T SWITCH_VALUE -T tcheck -T tlist \ 172 -T ucp_type_table -T UIVAL -T uschar -T UsedAttr -T USERFN_ENTRY \ 173 -T WAIT_TYPE -T warn_type -T Word \ 173 174 $$file ; done) 174 175 1.8.3/branches/devel/src/bsd.c
r1253 r1267 1070 1070 1071 1071 if (FD_ISSET(sock, &input_set)) { 1072 if (!info_slave_halted) {1073 addr_len = sizeof(addr);1074 newsock = accept(sock, (struct sockaddr *) &addr, &addr_len);1075 if (newsock < 0) {1076 if (test_connection(newsock) < 0)1077 continue;/* this should _not_ be return. */1078 }1079 ndescriptors++;1080 query_info_slave(newsock);1081 if (newsock >= maxd)1082 maxd = newsock + 1;1083 } else 1084 setup_desc(sock, false);1072 if (!info_slave_halted) { 1073 addr_len = sizeof(addr); 1074 newsock = accept(sock, (struct sockaddr *) &addr, &addr_len); 1075 if (newsock < 0) { 1076 if (test_connection(newsock) < 0) 1077 continue; /* this should _not_ be return. */ 1078 } 1079 ndescriptors++; 1080 query_info_slave(newsock); 1081 if (newsock >= maxd) 1082 maxd = newsock + 1; 1083 } else 1084 setup_desc(sock, false); 1085 1085 } 1086 1086 #ifdef HAS_OPENSSL 1087 1087 if (sslsock && FD_ISSET(sslsock, &input_set)) { 1088 if (!info_slave_halted) {1089 addr_len = sizeof(addr);1090 newsock = accept(sslsock, (struct sockaddr *) &addr, &addr_len);1091 if (newsock < 0) {1092 if (test_connection(newsock) < 0)1093 continue;/* this should _not_ be return. */1094 }1095 ndescriptors++;1096 query_info_slave(newsock);1097 if (newsock >= maxd)1098 maxd = newsock + 1;1099 } else1100 setup_desc(sslsock, true);1088 if (!info_slave_halted) { 1089 addr_len = sizeof(addr); 1090 newsock = accept(sslsock, (struct sockaddr *) &addr, &addr_len); 1091 if (newsock < 0) { 1092 if (test_connection(newsock) < 0) 1093 continue; /* this should _not_ be return. */ 1094 } 1095 ndescriptors++; 1096 query_info_slave(newsock); 1097 if (newsock >= maxd) 1098 maxd = newsock + 1; 1099 } else 1100 setup_desc(sslsock, true); 1101 1101 } 1102 1102 #endif 1103 1103 #else /* INFO_SLAVE */ 1104 if (FD_ISSET(sock, &input_set)) 1105 setup_desc(sock, false);1104 if (FD_ISSET(sock, &input_set)) 1105 setup_desc(sock, false); 1106 1106 #ifdef HAS_OPENSSL 1107 if (sslsock && FD_ISSET(sslsock, &input_set)) 1108 setup_desc(sslsock, true);1107 if (sslsock && FD_ISSET(sslsock, &input_set)) 1108 setup_desc(sslsock, true); 1109 1109 #endif 1110 1110 #endif … … 2126 2126 { 2127 2127 if (*userstring) { 2128 mush_free((Malloc_t) * userstring, "userstring");2128 mush_free((Malloc_t) * userstring, "userstring"); 2129 2129 *userstring = NULL; 2130 2130 } 1.8.3/branches/devel/src/cque.c
r1235 r1267 262 262 uint32_t pid = top_pid; 263 263 264 if (im_count(queue_map) >= (int) MAX_PID) {264 if (im_count(queue_map) >= (int) MAX_PID) { 265 265 do_rawlog(LT_ERR, 266 T("There are %ld queue entries! That's too many. Failing to add another."), 267 (long)im_count(queue_map)); 266 T 267 ("There are %ld queue entries! That's too many. Failing to add another."), 268 (long) im_count(queue_map)); 268 269 return 0; 269 270 } 1.8.3/branches/devel/src/csrimalloc.c
r1159 r1267 729 729 */ 730 730 Word *_malloc_rovers[MAXBINS + 1] = { NULL }; 731 731 732 const size_t _malloc_binmax[MAXBINS] = { 732 733 8, 16, 32, 64, 128, 256, 512, 1024 733 734 }; 735 734 736 int _malloc_firstbin = 0; 735 737 int _malloc_lastbin = 0; … … 998 1000 univptr_t 999 1001 erealloc(univptr_t ptr, size_t nbytes); 1000 Free_t1001 free(univptr_t cp);1002 Free_t1003 cfree(univptr_t cp);1002 Free_t 1003 free(univptr_t cp); 1004 Free_t 1005 cfree(univptr_t cp); 1004 1006 #endif /* CSRI_TRACE */ 1005 1007 1.8.3/branches/devel/src/extchat.c
r1260 r1267 103 103 CHAN *channels; /**< Pointer to channel list */ 104 104 105 extern int rhs_present; /* from command.c */105 extern int rhs_present; /* from command.c */ 106 106 107 107 static PRIV priv_table[] = { … … 2034 2034 return; 2035 2035 } 2036 2036 2037 2037 test_channel(player, name, c); 2038 2038 u = onchannel(player, c); … … 2041 2041 return; 2042 2042 } 2043 2043 2044 2044 if (!rhs_present) { 2045 if (strlen(CUtitle(u)) == 0) 2046 notify_format(player, T("You have no title set on <%s>."), ChanName(c)); 2047 else 2048 notify_format(player, T("Your title on <%s> is '%s'."), ChanName(c), CUtitle(u)); 2049 return; 2050 } 2051 2045 if (strlen(CUtitle(u)) == 0) 2046 notify_format(player, T("You have no title set on <%s>."), ChanName(c)); 2047 else 2048 notify_format(player, T("Your title on <%s> is '%s'."), ChanName(c), 2049 CUtitle(u)); 2050 return; 2051 } 2052 2052 2053 if (!title) 2053 2054 title = (const char *) ""; … … 2273 2274 2274 2275 /* ARGSUSED */ 2275 FUNCTION(fun_cbufferadd) { 2276 FUNCTION(fun_cbufferadd) 2277 { 2276 2278 CHAN *c; 2277 2279 dbref victim; 2278 2280 2279 2281 // Person must be able to do nospoof cemits. 2280 if (!command_check_byname(executor, "@cemit") || 2281 fun->flags & FN_NOSIDEFX) { 2282 if (!command_check_byname(executor, "@cemit") || fun->flags & FN_NOSIDEFX) { 2282 2283 safe_str(T(e_perm), buff, bp); 2283 2284 return; 2284 2285 } 2285 2286 2286 // Find the channel. 2287 2287 if (!args[0] || !*args[0]) { … … 2289 2289 return; 2290 2290 } 2291 2292 2291 // Make sure we have text. 2293 2292 if (!args[1] || !*args[1]) { … … 2300 2299 if (nargs == 3 && parse_boolean(args[2])) { 2301 2300 // Person must be able to do nospoof cemits. 2302 if (!command_check_byname(executor, "@nscemit") || 2303 fun->flags & FN_NOSIDEFX) { 2301 if (!command_check_byname(executor, "@nscemit") || fun->flags & FN_NOSIDEFX) { 2304 2302 safe_str(T(e_perm), buff, bp); 2305 2303 return; … … 2307 2305 victim = enactor; 2308 2306 } 2309 2310 2307 // Get the message. 2311 2308 switch (find_channel(args[0], &c, executor)) { … … 3531 3528 u = onchannel(player, chan); 3532 3529 if (!u && !Chan_Can_Join(chan, player)) { 3533 notify(player, T("CHAT: You must be able to join a channel to recall from it.")); 3530 notify(player, 3531 T("CHAT: You must be able to join a channel to recall from it.")); 3534 3532 return; 3535 3533 } 1.8.3/branches/devel/src/fundb.c
r1240 r1267 38 38 char const *pattern, ATTR *atr, void *args); 39 39 static dbref 40 dbwalk(char *buff, char **bp, dbref executor, dbref enactor, 41 int type, dbref loc, dbref after, int skipdark, 42 int start, int count, int *retcount); 40 41 42 dbwalk(char *buff, char **bp, dbref executor, dbref enactor, 43 int type, dbref loc, dbref after, int skipdark, 44 int start, int count, int *retcount); 43 45 44 46 … … 200 202 char *attr; 201 203 ATTR *a; 202 204 203 205 if (nargs == 1) { 204 attr = strchr(args[0], '/');205 if (!attr) {206 safe_format(buff, bp, T("#-1 BAD ARGUMENT FORMAT TO %s"), called_as);207 return;208 }209 *attr++ = '\0';206 attr = strchr(args[0], '/'); 207 if (!attr) { 208 safe_format(buff, bp, T("#-1 BAD ARGUMENT FORMAT TO %s"), called_as); 209 return; 210 } 211 *attr++ = '\0'; 210 212 } else { 211 attr = args[1];213 attr = args[1]; 212 214 } 213 215 1.8.3/branches/devel/src/funmath.c
r1258 r1267 1799 1799 char *ptr; 1800 1800 char numbuff[BUFFER_LEN], *nbp; 1801 1801 1802 1802 1803 1803 // Base 36 by default. … … 1830 1830 tobase = to_base_64; 1831 1831 } 1832 1833 1832 // Parse it. 1834 1833 ptr = trim_space_sep(args[0], ' '); 1.8.3/branches/devel/src/game.c
r1227 r1267 84 84 /* declarations */ 85 85 GLOBALTAB globals = { 0, "", 0, 0, 0, 0, 0, 0, 0, 0 }; 86 86 87 static int epoch = 0; 87 88 static int reserved; /**< Reserved file descriptor */ … … 934 935 db_close(f); 935 936 } 936 } else /* Close the panicdb file handle */937 } else /* Close the panicdb file handle */ 937 938 db_close(f); 938 939 1.8.3/branches/devel/src/info_master.c
r1224 r1267 130 130 } 131 131 } 132 133 134 132 #ifndef AF_LOCAL 135 133 /* Use Posix.1g names. */ … … 210 208 if (FD_ISSET(n, &info_pending)) 211 209 query_info_slave(n); 212 210 213 211 return true; 214 212 } … … 231 229 if (!make_info_slave()) { 232 230 FD_CLR(fd, &info_pending); 233 closesocket(fd); /* Just drop the connection if the slave gets halted.234 A subsequent reconnect will work. */231 closesocket(fd); /* Just drop the connection if the slave gets halted. 232 A subsequent reconnect will work. */ 235 233 } 236 234 return; 1.8.3/branches/devel/src/intmap.c
r1216 r1267 81 81 (Passing a NULL pointer instead of a map). */ 82 82 int64_t 83 im_count(intmap * im)83 im_count(intmap *im) 84 84 { 85 85 if (im) … … 105 105 106 106 static void 107 pat_destroy(patricia * node)107 pat_destroy(patricia *node) 108 108 { 109 109 int n; … … 125 125 */ 126 126 void 127 im_destroy(intmap * im)127 im_destroy(intmap *im) 128 128 { 129 129 if (im) { … … 141 141 /* Returns the node matching the key or its prefix */ 142 142 static patricia * 143 pat_search(patricia * node, im_key key, int bit)143 pat_search(patricia *node, im_key key, int bit) 144 144 { 145 145 assert(node); … … 157 157 */ 158 158 void * 159 im_find(intmap * im, im_key key)159 im_find(intmap *im, im_key key) 160 160 { 161 161 patricia *node; … … 178 178 */ 179 179 bool 180 im_exists(intmap * im, im_key key)180 im_exists(intmap *im, im_key key) 181 181 { 182 182 patricia *node; … … 195 195 */ 196 196 bool 197 im_insert(intmap * im, im_key key, void *data)197 im_insert(intmap *im, im_key key, void *data) 198 198 { 199 199 patricia *here, *newnode, *prev = NULL; … … 270 270 */ 271 271 bool 272 im_delete(intmap * im, im_key key)272 im_delete(intmap *im, im_key key) 273 273 { 274 274 patricia *parent = NULL, *firstparent = NULL, *grandparent = NULL; … … 376 376 377 377 static void 378 pat_list_nodes(patricia * node, FILE * fp)378 pat_list_nodes(patricia *node, FILE * fp) 379 379 { 380 380 int n; … … 407 407 408 408 static void 409 pat_list_links(patricia * node, FILE * fp)409 pat_list_links(patricia *node, FILE * fp) 410 410 { 411 411 int i; … … 442 442 */ 443 443 void 444 im_dump_graph(intmap * im, const char *filename)444 im_dump_graph(intmap *im, const char *filename) 445 445 { 446 446 FILE *fp; … … 473 473 /** @stats/tables line */ 474 474 void 475 im_stats(dbref player, intmap * im, const char *name)476 { 477 notify_format(player, "%-11s %7lld %7u", name, im->count,475 im_stats(dbref player, intmap *im, const char *name) 476 { 477 notify_format(player, "%-11s %7lld %7u", name, (long long) im->count, 478 478 (unsigned int) (sizeof(*im) + (sizeof(patricia) * im->count))); 479 479 } 1.8.3/branches/devel/src/notify.c
r1159 r1267 822 822 823 823 if (!((flags & NA_NOENTER) || ((flags & NA_PROMPT) 824 && !(d-> 825 conn_flags & 824 && !(d->conn_flags & 826 825 CONN_PROMPT_NEWLINES)))) { 827 826 if ((poutput == NA_PUEBLO) || (poutput == NA_NPUEBLO)) { 1.8.3/branches/devel/src/parse.c
r1238 r1267 805 805 } 806 806 break; 807 case ESC_CHAR: /* ANSI escapes. */807 case ESC_CHAR: /* ANSI escapes. */ 808 808 /* Skip over until the 'm' that matches the end. */ 809 809 for (; *str && **str && **str != 'm'; (*str)++) 1.8.3/branches/devel/src/pcre.c
r1151 r1267 1253 1253 1254 1254 int 1255 pcre_get_substring_list(const char *subject, int *ovector, int stringcount, 1256 const char ***listptr); 1255 1256 1257 pcre_get_substring_list(const char *subject, int *ovector, int stringcount, 1258 const char ***listptr); 1257 1259 1258 1260 int … … 1337 1339 1338 1340 int 1339 pcre_get_substring(const char *subject, int *ovector, int stringcount, 1340 int stringnumber, const char **stringptr); 1341 1342 1343 pcre_get_substring(const char *subject, int *ovector, int stringcount, 1344 int stringnumber, const char **stringptr); 1341 1345 1342 1346 int … … 1388 1392 1389 1393 int 1390 pcre_get_named_substring(const pcre * code, const char *subject, int *ovector, 1391 int stringcount, const char *stringname, 1392 const char **stringptr); 1394 1395 1396 pcre_get_named_substring(const pcre * code, const char *subject, int *ovector, 1397 int stringcount, const char *stringname, 1398 const char **stringptr); 1393 1399 1394 1400 int … … 2269 2275 2270 2276 static BOOL 2271 compile_regex(int, int, int *, uschar **, const uschar **, int *, BOOL, int, 2272 int *, int *, branch_chain *, compile_data *); 2277 2278 2279 compile_regex(int, int, int *, uschar **, const uschar **, int *, BOOL, int, 2280 int *, int *, branch_chain *, compile_data *); 2273 2281 2274 2282 1.8.3/branches/devel/src/set.c
r1241 r1267 64 64 { 65 65 dbref thing; 66 char *eon; /* End Of Name */66 char *eon; /* End Of Name */ 67 67 char *myenv[10]; 68 68 int i; … … 79 79 if (IsPlayer(thing)) { 80 80 if (*newname == '"') { 81 for (; *newname && ((*newname == '"') 82 || isspace((unsigned char) *newname)); 83 newname++) ; 84 eon = newname; 85 while (*eon && (*eon != '"')) { 86 while (*eon && (*eon != '"')) 87 eon++; 88 if (*eon == '"') { 89 *eon++ = '\0'; 90 while (*eon && isspace((unsigned char) *eon)) 91 eon++; 92 break; 93 } 81 for (; *newname && ((*newname == '"') 82 || isspace((unsigned char) *newname)); newname++) ; 83 eon = newname; 84 while (*eon && (*eon != '"')) { 85 while (*eon && (*eon != '"')) 86 eon++; 87 if (*eon == '"') { 88 *eon++ = '\0'; 89 while (*eon && isspace((unsigned char) *eon)) 90 eon++; 91 break; 94 92 } 93 } 95 94 } else { 96 eon = newname;97 while (*eon && !isspace((unsigned char) *eon))98 eon++;99 if (*eon) 100 *eon++ = '\0';95 eon = newname; 96 while (*eon && !isspace((unsigned char) *eon)) 97 eon++; 98 if (*eon) 99 *eon++ = '\0'; 101 100 } 102 101 if (!ok_player_name(newname, player, thing)) { 1.8.3/branches/devel/src/ssl_slave.c
r1177 r1267 216 216 217 217 static int 218 parse_arguments(int argc, char **argv, char *elog, char *mhost, 219 Port_t *mport, Port_t *lport, char *kfile, char *cafl); 220 static void logout_sock(CDESC * d); 221 static void shutdownsock(CDESC * d); 218 219 220 parse_arguments(int argc, char **argv, char *elog, char *mhost, 221 Port_t *mport, Port_t *lport, char *kfile, char *cafl); 222 static void logout_sock(CDESC *d); 223 static void shutdownsock(CDESC *d); 222 224 static CDESC *initializesock(int s, char *addr, char *ip, int use_ssl); 223 int process_output(CDESC * d);224 static int process_input(CDESC * d, int output_ready);225 static void process_input_helper(CDESC * d, char *tbuf1, int got);225 int process_output(CDESC *d); 226 static int process_input(CDESC *d, int output_ready); 227 static void process_input_helper(CDESC *d, char *tbuf1, int got); 226 228 static void close_sockets(void); 227 229 static CDESC *connect_to_mush(const char *mush_host, Port_t mport); … … 229 231 static int test_connection(int newsock); 230 232 static CDESC *new_connection(int oldsock, int *result, int use_ssl); 231 static int queue_newwrite(CDESC * d, const unsigned char *b, int n); 232 static int send_text(CDESC * d, const unsigned char *b); 233 static int send_concentor_command(CDESC * d, const unsigned char *b); 234 static int send_concentor_text(CDESC * d, int player_id, 235 const unsigned char *b); 233 static int queue_newwrite(CDESC *d, const unsigned char *b, int n); 234 static int send_text(CDESC *d, const unsigned char *b); 235 static int send_concentor_command(CDESC *d, const unsigned char *b); 236 static int send_concentor_text(CDESC *d, int player_id, const unsigned char *b); 236 237 static void process_commands(void); 237 238 … … 408 409 /* Send text to the MUSH from a player */ 409 410 static int 410 send_concentor_message(CDESC * d, int player_id, const unsigned char *b)411 send_concentor_message(CDESC *d, int player_id, const unsigned char *b) 411 412 { 412 413 unsigned char *message = … … 418 419 /* Send text with a player_id of -1 */ 419 420 static int 420 send_concentor_command(CDESC * d, const unsigned char *b)421 send_concentor_command(CDESC *d, const unsigned char *b) 421 422 { 422 423 return send_concentrator_message(d, -1, b); … … 530 531 531 532 static void 532 queue_to_player(CDESC * d)533 queue_to_player(CDESC *d) 533 534 { 534 535 /* Parse a concentrator message from the MUSH in text blocks on … … 539 540 540 541 static void 541 queue_to_mush(CDESC * d)542 queue_to_mush(CDESC *d) 542 543 { 543 544 /* Parse some text from a player and queue it to the MUSH as … … 634 635 */ 635 636 static void 636 shutdownsock(CDESC * d)637 shutdownsock(CDESC *d) 637 638 { 638 639 … … 722 723 */ 723 724 int 724 process_output(CDESC * d)725 process_output(CDESC *d) 725 726 { 726 727 struct text_block **qp, *cur; … … 815 816 816 817 static void 817 save_command(CDESC * d, const unsigned char *command)818 save_command(CDESC *d, const unsigned char *command) 818 819 { 819 820 add_to_queue(&d->input, command, u_strlen(command) + 1); … … 822 823 823 824 static void 824 process_input_helper(CDESC * d, char *tbuf1, int got)825 process_input_helper(CDESC *d, char *tbuf1, int got) 825 826 { 826 827 unsigned char *p, *pend, *q, *qend; … … 871 872 /* ARGSUSED */ 872 873 static int 873 process_input(CDESC * d, int output_ready)874 process_input(CDESC *d, int output_ready) 874 875 { 875 876 int got = 0; … … 1053 1054 1054 1055 static int 1055 send_text(CDESC * d, const unsigned char *b)1056 send_text(CDESC *d, const unsigned char *b) 1056 1057 { 1057 1058 int l = u_strlen(b); … … 1066 1067 */ 1067 1068 static int 1068 queue_newwrite(CDESC * d, const unsigned char *b, int n)1069 queue_newwrite(CDESC *d, const unsigned char *b, int n) 1069 1070 { 1070 1071 int space; 1.8.3/branches/devel/src/tables.c
r1243 r1267 42 42 43 43 char to_base_64[] = 44 "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_";44 "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"; 45 45 46 46 char from_base_36[256] = {
