Changeset 1159
- Timestamp:
- 11/22/07 12:53:02 (10 months ago)
- Files:
-
- 1.8.3/branches/devel/hdrs/ansi.h (modified) (1 diff)
- 1.8.3/branches/devel/hdrs/shs.h (modified) (1 diff)
- 1.8.3/branches/devel/src/Makefile.in (modified) (1 diff)
- 1.8.3/branches/devel/src/bsd.c (modified) (1 diff)
- 1.8.3/branches/devel/src/csrimalloc.c (modified) (1 diff)
- 1.8.3/branches/devel/src/fundb.c (modified) (3 diffs)
- 1.8.3/branches/devel/src/help.c (modified) (11 diffs)
- 1.8.3/branches/devel/src/ident.c (modified) (4 diffs)
- 1.8.3/branches/devel/src/lock.c (modified) (1 diff)
- 1.8.3/branches/devel/src/markup.c (modified) (5 diffs)
- 1.8.3/branches/devel/src/notify.c (modified) (2 diffs)
- 1.8.3/branches/devel/src/shs.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
1.8.3/branches/devel/hdrs/ansi.h
r1143 r1159 90 90 } ansi_data; 91 91 92 int read_raw_ansi_data(ansi_data * store, const char *codes); 93 int write_raw_ansi_data(ansi_data * old, ansi_data * cur, char *buff, 94 char **bp); 92 int read_raw_ansi_data(ansi_data *store, const char *codes); 93 int write_raw_ansi_data(ansi_data *old, ansi_data *cur, char *buff, char **bp); 95 94 96 void define_ansi_data(ansi_data * store, const char *str);97 int write_ansi_data(ansi_data * cur, char *buff, char **bp);95 void define_ansi_data(ansi_data *store, const char *str); 96 int write_ansi_data(ansi_data *cur, char *buff, char **bp); 98 97 99 98 100 void nest_ansi_data(ansi_data * old, ansi_data *cur);99 void nest_ansi_data(ansi_data *old, ansi_data *cur); 101 100 102 101 #define MARKUP_COLOR 'c' 1.8.3/branches/devel/hdrs/shs.h
r964 r1159 40 40 } SHS_INFO; 41 41 42 void shsInit(SHS_INFO * shsInfo);43 void shsUpdate(SHS_INFO * shsInfo, const BYTE *buffer, int count);44 void shsFinal(SHS_INFO * shsInfo);42 void shsInit(SHS_INFO *shsInfo); 43 void shsUpdate(SHS_INFO *shsInfo, const BYTE *buffer, int count); 44 void shsFinal(SHS_INFO *shsInfo); 45 45 #endif 1.8.3/branches/devel/src/Makefile.in
r1143 r1159 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 acsflag -T aig_func -T ALIST -T ansi_string -T ATRALIAS -T ATTR \ 151 -T BOOL -T bool -T boolexp -T boolexp_type -T BQUE -T branch_chain \ 152 -T BUFFERQ -T bvm_opcode -T BYTE -T CDESC -T CHAN -T CHANLIST \ 153 -T CHANUSER -T chunk_reference_t -T CNode -T COMLIST \ 154 -T command_func -T COMMAND_INFO -T comp_func -T compile_data \ 155 -T COMSORTSTRUC -T config_func -T CType -T dbref -T Debug_Info \ 156 -T DESC -T dfa_match_data -T eptrblock -T EVAL_CONTEXT -T FBLOCK \ 157 -T fd_type -T FLAG -T FLAG_ALIAS -T FLAGSPACE -T folder_array \ 158 -T FUN -T function_func -T FUNTAB -T GLOBALTAB -T HASHENT \ 159 -T HASHTAB -T heapframe -T IVAL -T list_type_list -T lock_list \ 160 -T lock_type -T LOCKMSGINFO -T LONG -T MAIL -T mail_flag \ 161 -T makerecord -T markup_information -T match_data -T MATH -T MEM \ 162 -T na_lookup -T NVAL -T object_flag_type -T OPTTAB \ 163 -T pcre_study_data -T pcre_uint16 -T pcre_uint32 -T PE_Info \ 164 -T PENNCONF -T PENNCONFGROUP -T Port_t -T PRIV -T privbits \ 165 -T PTAB -T ptab_entry -T qsort_func -T real_pcre \ 166 -T recursion_info -T Region -T RegionHeader -T s_rec -T slab \ 167 -T sqlplatform -T StrNode -T StrTree -T switch_mask \ 168 -T SWITCH_VALUE -T tcheck -T tlist -T UIVAL -T uschar -T UsedAttr \ 169 -T USERFN_ENTRY -T WAIT_TYPE -T warn_type -T Word \ 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 \ 170 173 $$file ; done) 171 174 1.8.3/branches/devel/src/bsd.c
r1143 r1159 2101 2101 { 2102 2102 if (*userstring) { 2103 mush_free((Malloc_t) * userstring, "userstring");2103 mush_free((Malloc_t) *userstring, "userstring"); 2104 2104 *userstring = NULL; 2105 2105 } 1.8.3/branches/devel/src/csrimalloc.c
r964 r1159 998 998 univptr_t 999 999 erealloc(univptr_t ptr, size_t nbytes); 1000 Free_t1001 free(univptr_t cp);1002 Free_t1003 cfree(univptr_t cp);1000 Free_t 1001 free(univptr_t cp); 1002 Free_t 1003 cfree(univptr_t cp); 1004 1004 #endif /* CSRI_TRACE */ 1005 1005 1.8.3/branches/devel/src/fundb.c
r964 r1159 1224 1224 ltype = get_locktype(p); 1225 1225 1226 if (GoodObject(it) && (ltype != NULL)1227 && Can_Read_Lock(executor, it, ltype)) {1226 if (GoodObject(it) && (ltype !=NULL) 1227 &&Can_Read_Lock(executor, it, ltype)) { 1228 1228 ll = getlockstruct(it, ltype); 1229 1229 if (ll) { … … 1263 1263 1264 1264 if ((ltype = strchr(args[0], '/'))) { 1265 *ltype ++ = '\0';1265 *ltype ++ = '\0'; 1266 1266 upcasestr(ltype); 1267 1267 } … … 1307 1307 ltype = get_locktype(p); 1308 1308 1309 if (!GoodObject(it) || (ltype == NULL) || !Can_Read_Lock(executor, it, ltype)) {1309 if (!GoodObject(it) || (ltype == NULL) ||!Can_Read_Lock(executor, it, ltype)) { 1310 1310 safe_str("#-1", buff, bp); 1311 1311 return; 1.8.3/branches/devel/src/help.c
r1157 r1159 29 29 static int help_init = 0; 30 30 31 static void do_new_spitfile(dbref player, char *arg1, help_file * help_dat);32 static const char *string_spitfile(help_file * help_dat, char *arg1);33 static help_indx *help_find_entry(help_file * help_dat, const char *the_topic);34 static char **list_matching_entries(const char *pattern,35 help_file *help_dat, int *len);31 static void do_new_spitfile(dbref player, char *arg1, help_file *help_dat); 32 static const char *string_spitfile(help_file *help_dat, char *arg1); 33 static help_indx *help_find_entry(help_file *help_dat, const char *the_topic); 34 static char **list_matching_entries(const char *pattern, 35 help_file *help_dat, int *len); 36 36 static void free_entry_list(char **); 37 static const char *normalize_entry(help_file * help_dat, const char *arg1);38 39 static void help_build_index(help_file * h, int restricted);37 static const char *normalize_entry(help_file *help_dat, const char *arg1); 38 39 static void help_build_index(help_file *h, int restricted); 40 40 41 41 /** Linked list of help topic names. */ … … 76 76 if (len == 0) 77 77 notify_format(player, T("No entries matching '%s' were found."), 78 arg_left);78 arg_left); 79 79 else if (len == 1) 80 80 do_new_spitfile(player, *entries, h); … … 87 87 *bp = '\0'; 88 88 notify_format(player, T("Here are the entries which match '%s':\n%s"), 89 arg_left, buff);89 arg_left, buff); 90 90 } 91 91 free_entry_list(entries); … … 176 176 177 177 static void 178 do_new_spitfile(dbref player, char *arg1, help_file * help_dat)178 do_new_spitfile(dbref player, char *arg1, help_file *help_dat) 179 179 { 180 180 help_indx *entry = NULL; … … 260 260 261 261 static help_indx * 262 help_find_entry(help_file * help_dat, const char *the_topic)262 help_find_entry(help_file *help_dat, const char *the_topic) 263 263 { 264 264 help_indx *entry = NULL; … … 349 349 350 350 static void 351 help_build_index(help_file * h, int restricted)351 help_build_index(help_file *h, int restricted) 352 352 { 353 353 long bigpos, pos = 0; … … 512 512 513 513 static const char * 514 normalize_entry(help_file * help_dat, const char *arg1)514 normalize_entry(help_file *help_dat, const char *arg1) 515 515 { 516 516 static char the_topic[LINE_SIZE + 2]; … … 528 528 529 529 static const char * 530 string_spitfile(help_file * help_dat, char *arg1)530 string_spitfile(help_file *help_dat, char *arg1) 531 531 { 532 532 help_indx *entry = NULL; … … 595 595 } else { 596 596 *len = 1; 597 buff = mush_malloc(sizeof(char **), "help.search");597 buff = mush_malloc(sizeof(char **), "help.search"); 598 598 *buff = entry->topic + offset; 599 599 return buff; … … 601 601 } 602 602 603 buff = mush_calloc(help_dat->entries, sizeof(char *), "help.search");603 buff = mush_calloc(help_dat->entries, sizeof(char *), "help.search"); 604 604 *len = 0; 605 605 … … 614 614 615 615 static void 616 free_entry_list(char **entries) 616 free_entry_list(char **entries) 617 617 { 618 618 if (entries) 1.8.3/branches/devel/src/ident.c
r1144 r1159 77 77 struct sockaddr *laddr, socklen_t llen, int *timeout); 78 78 79 static int id_query(ident_t * id,79 static int id_query(ident_t *id, 80 80 struct sockaddr *laddr, 81 81 socklen_t llen, 82 82 struct sockaddr *faddr, socklen_t flen, int *timeout); 83 83 84 static void id_close(ident_t * id);85 86 static int id_parse(ident_t * id, int *timeout, IDENT ** ident);84 static void id_close(ident_t *id); 85 86 static int id_parse(ident_t *id, int *timeout, IDENT ** ident); 87 87 static IDENT *ident_lookup(int fd, int *timeout); 88 88 … … 255 255 256 256 static void 257 id_close(ident_t * id)257 id_close(ident_t *id) 258 258 { 259 259 closesocket(id->fd); … … 269 269 270 270 static int 271 id_query(ident_t * id, struct sockaddr *laddr, socklen_t llen,271 id_query(ident_t *id, struct sockaddr *laddr, socklen_t llen, 272 272 struct sockaddr *faddr, socklen_t flen, int *timeout) 273 273 { … … 390 390 391 391 static int 392 id_parse(ident_t * id, int *timeout, IDENT ** ident)392 id_parse(ident_t *id, int *timeout, IDENT ** ident) 393 393 { 394 394 char c, *cp, *tmp_charset = NULL; 1.8.3/branches/devel/src/lock.c
r1051 r1159 878 878 for (lm = lock_msgs; lm->type; lm++) { 879 879 if (!strcmp(lm->type, ltype)) 880 break;880 break; 881 881 } 882 882 if (lm->type) { 1.8.3/branches/devel/src/markup.c
r1085 r1159 401 401 402 402 int 403 write_ansi_data(ansi_data * cur, char *buff, char **bp)403 write_ansi_data(ansi_data *cur, char *buff, char **bp) 404 404 { 405 405 int retval = 0; … … 465 465 466 466 void 467 nest_ansi_data(ansi_data * old, ansi_data *cur)467 nest_ansi_data(ansi_data *old, ansi_data *cur) 468 468 { 469 469 if (cur->fore != 'n') { … … 484 484 #define EDGE_UP(x,y,z) ((x.bits & z) != (y->bits & z)) 485 485 int 486 write_raw_ansi_data(ansi_data * old, ansi_data *cur, char *buff, char **bp)486 write_raw_ansi_data(ansi_data *old, ansi_data *cur, char *buff, char **bp) 487 487 { 488 488 int f = 0; … … 556 556 557 557 void 558 define_ansi_data(ansi_data * store, const char *str)558 define_ansi_data(ansi_data *store, const char *str) 559 559 { 560 560 *store = ansi_null; … … 625 625 626 626 int 627 read_raw_ansi_data(ansi_data * store, const char *codes)627 read_raw_ansi_data(ansi_data *store, const char *codes) 628 628 { 629 629 int curnum; 1.8.3/branches/devel/src/notify.c
r1052 r1159 184 184 static void free_strings(struct notify_strings messages[]); 185 185 static void zero_strings(struct notify_strings messages[]); 186 static int output_ansichange(ansi_data * states, int *ansi_ptr,186 static int output_ansichange(ansi_data *states, int *ansi_ptr, 187 187 const unsigned char **ptr, char *buff, char **bp); 188 188 static unsigned char *notify_makestring(const char *message, … … 211 211 212 212 static int 213 output_ansichange(ansi_data * states, int *ansi_ptr,213 output_ansichange(ansi_data *states, int *ansi_ptr, 214 214 const unsigned char **ptr, char *buff, char **bp) 215 215 { 1.8.3/branches/devel/src/shs.c
r964 r1159 117 117 */ 118 118 void 119 shsInit(SHS_INFO * shsInfo)119 shsInit(SHS_INFO *shsInfo) 120 120 { 121 121 /* Set the h-vars to their initial values */ … … 132 132 133 133 134 static void shsTransform(SHS_INFO * shsInfo);134 static void shsTransform(SHS_INFO *shsInfo); 135 135 136 136 /* Perform the SHS transformation. Note that this code, like MD5, seems to … … 139 139 */ 140 140 static void 141 shsTransform(SHS_INFO * shsInfo)141 shsTransform(SHS_INFO *shsInfo) 142 142 { 143 143 LONG W[80], temp; … … 342 342 */ 343 343 void 344 shsUpdate(SHS_INFO * shsInfo, const BYTE *buffer, int count)344 shsUpdate(SHS_INFO *shsInfo, const BYTE *buffer, int count) 345 345 { 346 346 /* Update bitcount */ … … 373 373 */ 374 374 void 375 shsFinal(SHS_INFO * shsInfo)375 shsFinal(SHS_INFO *shsInfo) 376 376 { 377 377 int count;
