Changeset 2100
- Timestamp:
- 03/26/08 20:40:57 (2 months ago)
- Files:
-
- libswish3/trunk/src/libswish3/config.c (modified) (2 diffs)
- libswish3/trunk/src/libswish3/header.c (modified) (1 diff)
- libswish3/trunk/src/libswish3/mime_types.c (modified) (2 diffs)
- libswish3/trunk/src/libswish3/namedbuffer.c (modified) (3 diffs)
- libswish3/trunk/src/libswish3/parser.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
libswish3/trunk/src/libswish3/config.c
r2098 r2100 205 205 a little awkward, but saves var names. 206 206 */ 207 tmpmeta = xmlHashLookup(config->metanames, (xmlChar*)SWISH_DEFAULT_METANAME);207 tmpmeta = swish_hash_fetch(config->metanames, (xmlChar*)SWISH_DEFAULT_METANAME); 208 208 tmpmeta->ref_cnt++; 209 209 tmpmeta->id = SWISH_META_DEFAULT_ID; 210 tmpmeta = xmlHashLookup(config->metanames, (xmlChar*)SWISH_TITLE_METANAME);210 tmpmeta = swish_hash_fetch(config->metanames, (xmlChar*)SWISH_TITLE_METANAME); 211 211 tmpmeta->ref_cnt++; 212 212 tmpmeta->id = SWISH_META_TITLE_ID; … … 260 260 261 261 /* same deal as metanames above */ 262 tmpprop = xmlHashLookup(config->properties, (xmlChar*)SWISH_PROP_DESCRIPTION);262 tmpprop = swish_hash_fetch(config->properties, (xmlChar*)SWISH_PROP_DESCRIPTION); 263 263 tmpprop->ref_cnt++; 264 264 tmpprop->id = SWISH_PROP_DESCRIPTION_ID; 265 tmpprop = xmlHashLookup(config->properties, (xmlChar*)SWISH_PROP_TITLE);265 tmpprop = swish_hash_fetch(config->properties, (xmlChar*)SWISH_PROP_TITLE); 266 266 tmpprop->ref_cnt++; 267 267 tmpprop->id = SWISH_PROP_TITLE_ID; libswish3/trunk/src/libswish3/header.c
r2098 r2100 148 148 /* is this an existing metaname? pull it from hash and update */ 149 149 if (swish_hash_exists( h->config->metanames, newname )) { 150 newmeta = xmlHashLookup( h->config->metanames, newname );150 newmeta = swish_hash_fetch( h->config->metanames, newname ); 151 151 } 152 152 else { libswish3/trunk/src/libswish3/mime_types.c
r2097 r2100 219 219 { 220 220 xmlChar * mime; 221 mime = xmlHashLookup( config->mimes, fileext );221 mime = swish_hash_fetch( config->mimes, fileext ); 222 222 if ( mime == NULL ) 223 223 { … … 235 235 xmlChar *deftype; 236 236 237 parser = xmlHashLookup( config->parsers, mime );237 parser = swish_hash_fetch( config->parsers, mime ); 238 238 239 239 if (SWISH_DEBUG > 9) 240 240 SWISH_DEBUG_MSG("using parser '%s' based on MIME '%s'", parser, mime ); 241 241 242 deftype = xmlHashLookup( config->parsers, (xmlChar *)SWISH_DEFAULT_PARSER ); /* error check?? */242 deftype = swish_hash_fetch( config->parsers, (xmlChar *)SWISH_DEFAULT_PARSER ); /* error check?? */ 243 243 244 244 if ( parser == NULL ) libswish3/trunk/src/libswish3/namedbuffer.c
r2096 r2100 131 131 { 132 132 xmlChar * nowhitesp; 133 xmlBufferPtr buf = xmlHashLookup(nb->hash, name);133 xmlBufferPtr buf = swish_hash_fetch(nb->hash, name); 134 134 135 135 if (!buf) … … 139 139 /* spring to life */ 140 140 add_name_to_hash(NULL, nb->hash, name); 141 buf = xmlHashLookup(nb->hash, name);141 buf = swish_hash_fetch(nb->hash, name); 142 142 } 143 143 … … 197 197 { 198 198 xmlBufferPtr buf; 199 buf = xmlHashLookup(nb->hash, key);199 buf = swish_hash_fetch(nb->hash, key); 200 200 return (xmlChar*)xmlBufferContent(buf); 201 201 } libswish3/trunk/src/libswish3/parser.c
r2098 r2100 293 293 294 294 /* change our internal name for this tag if it is aliased in config */ 295 alias = xmlHashLookup(parser_data->s3->config->tag_aliases, swishtag);295 alias = swish_hash_fetch(parser_data->s3->config->tag_aliases, swishtag); 296 296 if (alias) 297 297 { … … 1892 1892 1893 1893 if (tag != NULL) { 1894 prop = xmlHashLookup(parser_data->s3->config->properties, tag);1894 prop = swish_hash_fetch(parser_data->s3->config->properties, tag); 1895 1895 1896 1896 /* should we strip whitespace from this particular property ? */
