Changeset 974:2091bf698fb1 in freeDiameter for extensions/acl_wl
- Timestamp:
- Mar 15, 2013, 2:14:35 AM (11 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- extensions/acl_wl
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/acl_wl/aw_conf.l
r965 r974 96 96 <*>[[:alnum:]]+ | /* This rule is only useful to print a complete token in error messages */ 97 97 <*>. { 98 TRACE_ERROR("Unrecognized text on line %d col %d: '%s'. \n", yylloc->first_line, yylloc->first_column, yytext);98 TRACE_ERROR("Unrecognized text on line %d col %d: '%s'.", yylloc->first_line, yylloc->first_column, yytext); 99 99 return LEX_ERROR; 100 100 } -
extensions/acl_wl/aw_conf.y
r961 r974 74 74 if (aw_confin == NULL) { 75 75 ret = errno; 76 fd_log_debug("Unable to open extension configuration file %s for reading: %s \n", conffile, strerror(ret));76 fd_log_debug("Unable to open extension configuration file %s for reading: %s", conffile, strerror(ret)); 77 77 TRACE_DEBUG (INFO, "Error occurred, message logged -- configuration file."); 78 78 return ret; … … 102 102 103 103 if (ploc->first_line != ploc->last_line) 104 fd_log_debug("%s:%d.%d-%d.%d : %s \n", conffile, ploc->first_line, ploc->first_column, ploc->last_line, ploc->last_column, s);104 fd_log_debug("%s:%d.%d-%d.%d : %s", conffile, ploc->first_line, ploc->first_column, ploc->last_line, ploc->last_column, s); 105 105 else if (ploc->first_column != ploc->last_column) 106 fd_log_debug("%s:%d.%d-%d : %s \n", conffile, ploc->first_line, ploc->first_column, ploc->last_column, s);106 fd_log_debug("%s:%d.%d-%d : %s", conffile, ploc->first_line, ploc->first_column, ploc->last_column, s); 107 107 else 108 fd_log_debug("%s:%d.%d : %s \n", conffile, ploc->first_line, ploc->first_column, s);108 fd_log_debug("%s:%d.%d : %s", conffile, ploc->first_line, ploc->first_column, s); 109 109 } 110 110 -
extensions/acl_wl/aw_tree.c
r741 r974 116 116 117 117 #if 0 118 fd_log_debug("Parsed name %s as: \n", name);118 fd_log_debug("Parsed name %s as:", name); 119 119 for (i=0; i<=l; i++) 120 fd_log_debug(" str[%d] len: %d, v:%.*s \n", i, result->label[i].len, result->label[i].len, result->label[i].str);120 fd_log_debug(" str[%d] len: %d, v:%.*s", i, result->label[i].len, result->label[i].len, result->label[i].str); 121 121 #endif /* 0 */ 122 122 return 0; … … 179 179 for (li = sub->next; li != sub; li = li->next) { 180 180 struct tree_item * ti = (struct tree_item *)li; 181 fd_log_debug("%*s%s", indent * 2, "", ti->str?:"*"); 181 char buf[1024]; 182 snprintf(buf, sizeof(buf), "%*s%s", indent * 2, "", ti->str?:"*"); 182 183 if (ti->leaf) 183 fd_log_debug(" (flag:%x)", ti->flags);184 fd_log_debug(" \n");184 snprintf(buf+strlen(buf), sizeof(buf)-strlen(buf), " (flag:%x)", ti->flags); 185 fd_log_debug("%s", buf); 185 186 tree_dump(&ti->children, indent + 1); 186 187 } … … 190 191 void aw_tree_dump(void) 191 192 { 192 fd_log_debug("[acl_wl] tree dump:\n(root)\n"); 193 fd_log_debug("[acl_wl] tree dump:"); 194 fd_log_debug("(root)"); 193 195 tree_dump(&tree_root, 1); 194 fd_log_debug("[acl_wl] end of dump \n");196 fd_log_debug("[acl_wl] end of dump"); 195 197 } 196 198 … … 208 210 CHECK_FCT_DO( parse_name(name, &sn), 209 211 { 210 fd_log_debug("The name '%s' contains too many labels, try a generic (*) or recompile with bigger AW_TREE_MAXDEPTH value (cur: %d) \n", name, AW_TREE_MAXDEPTH);212 fd_log_debug("The name '%s' contains too many labels, try a generic (*) or recompile with bigger AW_TREE_MAXDEPTH value (cur: %d)", name, AW_TREE_MAXDEPTH); 211 213 return EINVAL; 212 214 } ); … … 229 231 ti = (struct tree_item *)(senti->next); 230 232 if (ti->str == NULL) { 231 fd_log_debug("[acl_wl] Warning: entry '%s' is superseeded by a generic entry at label %d, ignoring. \n", name, lbl + 1);233 fd_log_debug("[acl_wl] Warning: entry '%s' is superseeded by a generic entry at label %d, ignoring.", name, lbl + 1); 232 234 return 0; 233 235 } … … 275 277 if (sn.label[0].str[0] == '*') { 276 278 if (!FD_IS_LIST_EMPTY(senti)) { 277 fd_log_debug("[acl_wl] Warning: entry '%s' overwrites previous more detailed entries, these are deleted. \n", name);279 fd_log_debug("[acl_wl] Warning: entry '%s' overwrites previous more detailed entries, these are deleted.", name); 278 280 delete_tree(senti); 279 281 } … … 286 288 ti = (struct tree_item *)(senti->next); 287 289 if (ti->str == NULL) { 288 fd_log_debug("[acl_wl] Warning: entry '%s' is superseeded by a generic entry at label 1, ignoring. \n", name);290 fd_log_debug("[acl_wl] Warning: entry '%s' is superseeded by a generic entry at label 1, ignoring.", name); 289 291 return 0; 290 292 } … … 310 312 /* We already had this label */ 311 313 if (ti->leaf) { 312 fd_log_debug("[acl_wl] Warning: entry '%s' is duplicated, merging the flags. \n", name);314 fd_log_debug("[acl_wl] Warning: entry '%s' is duplicated, merging the flags.", name); 313 315 ti->flags |= flags; 314 316 return 0;
Note: See TracChangeset
for help on using the changeset viewer.