Changeset 126

Show
Ignore:
Timestamp:
05/16/05 16:37:30
Author:
rachel
Message:

packet-decode renamed to packet-to-text

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openpgpsdk/trunk/examples/packet-dump.c

    r120 r126  
    33#include "packet.h" 
    44#include "packet-parse.h" 
    5 #include "packet-decode.h" 
     5#include "packet-to-text.h" 
    66#include "util.h" 
    77#include <unistd.h> 
     
    6363    } 
    6464 
    65 static void print_decoded(char *label, decoded_t *decoded, int indentlevel) 
     65static void print_text(char *label, text_t *text, int indentlevel) 
    6666    { 
    6767    int i=0; 
     
    7575    /* these were recognised */ 
    7676 
    77     for(i=0 ; i<decoded->known.used ; i++)  
     77    for(i=0 ; i<text->known.used ; i++)  
    7878        { 
    7979        indent(indentlevel+1); 
    80         printf("%s\n",decoded->known.strings[i]); 
     80        printf("%s\n",text->known.strings[i]); 
    8181        } 
    8282 
     
    8585    */ 
    8686 
    87     if(decoded->unknown.used) 
     87    if(text->unknown.used) 
    8888        { 
    8989        printf("\n"); 
     
    9191        printf("Not Recognised: "); 
    9292        } 
    93     for( i=0; i < decoded->unknown.used; i++)  
     93    for( i=0; i < text->unknown.used; i++)  
    9494        { 
    9595        indent(indentlevel+2); 
    96         printf("%s\n",decoded->unknown.strings[i]); 
     96        printf("%s\n",text->unknown.strings[i]); 
    9797        } 
    9898         
     
    154154    { 
    155155    const ops_parser_content_union_t *content=&content_->content; 
    156     decoded_t * decoded
     156    text_t * text
    157157    char *str; 
    158158 
     
    325325 
    326326    case OPS_PTAG_SS_PREFERRED_SKA: 
    327         decoded = decode_ss_preferred_ska(content->ss_preferred_ska); 
    328         print_decoded("Preferred Symmetric Algorithms",decoded,1); 
    329         decoded_free(decoded); 
     327        text = text_ss_preferred_ska(content->ss_preferred_ska); 
     328        print_text("Preferred Symmetric Algorithms",text,1); 
     329        text_free(text); 
    330330 
    331331        break; 
     
    338338 
    339339    case OPS_PTAG_SS_PREFERRED_HASH: 
    340         decoded = decode_ss_preferred_hash(content->ss_preferred_hash); 
    341         print_decoded("Preferred Hash Algorithms",decoded,1); 
    342         decoded_free(decoded); 
     340        text = text_ss_preferred_hash(content->ss_preferred_hash); 
     341        print_text("Preferred Hash Algorithms",text,1); 
     342        text_free(text); 
    343343        break; 
    344344 
    345345    case OPS_PTAG_SS_PREFERRED_COMPRESSION: 
    346         decoded = decode_ss_preferred_compression(content->ss_preferred_compression); 
    347         print_decoded("Preferred Compression Algorithms",decoded,1); 
    348         decoded_free(decoded); 
     346        text = text_ss_preferred_compression(content->ss_preferred_compression); 
     347        print_text("Preferred Compression Algorithms",text,1); 
     348        text_free(text); 
    349349        break; 
    350350         
     
    355355                      1); 
    356356 
    357         decoded = decode_ss_key_flags(content->ss_key_flags); 
    358         print_decoded(NULL, decoded, 1); 
    359         decoded_free(decoded); 
     357        text = text_ss_key_flags(content->ss_key_flags); 
     358        print_text(NULL, text, 1); 
     359        text_free(text); 
    360360 
    361361        break; 
     
    367367                      1); 
    368368 
    369         decoded = decode_ss_key_server_prefs(content->ss_key_server_prefs); 
    370         print_decoded(NULL, decoded, 1); 
    371         decoded_free(decoded); 
     369        text = text_ss_key_server_prefs(content->ss_key_server_prefs); 
     370        print_text(NULL, text, 1); 
     371        text_free(text); 
    372372 
    373373        break; 
     
    379379                      1); 
    380380 
    381         decoded = decode_ss_features(content->ss_features); 
    382         print_decoded(NULL,decoded,1); 
    383         decoded_free(decoded); 
     381        text = text_ss_features(content->ss_features); 
     382        print_text(NULL,text,1); 
     383        text_free(text); 
    384384 
    385385        break; 
     
    391391                   &content->ss_notation_data.flags, 
    392392                   2); 
    393         decoded = decode_ss_notation_data_flags(content->ss_notation_data); 
    394         print_decoded(NULL,decoded,2); 
    395         decoded_free(decoded); 
     393        text = text_ss_notation_data_flags(content->ss_notation_data); 
     394        print_text(NULL,text,2); 
     395        text_free(text); 
    396396 
    397397        /* xxx - TODO: print out UTF - rachel */ 
     
    451451                      1, 
    452452                      1); 
    453         str = decode_ss_revocation_reason_code(content->ss_revocation_reason.code); 
     453        str = text_ss_revocation_reason_code(content->ss_revocation_reason.code); 
    454454        print_string(NULL,str,1); 
    455455        /* xxx - todo : output text as UTF-8 string */ 
  • openpgpsdk/trunk/include/packet-to-text.h

    r123 r126  
    1 /** \file packet-decode.h 
    2  * packet decode related headers. 
     1/** \file packet-to_text.h 
    32 * 
    43 * $Id$ 
    54 */ 
    65 
    7 #ifndef OPS_PACKET_DECODE_H 
    8 #define OPS_PACKET_DECODE_H 
     6#ifndef OPS_PACKET_TO_TEXT_H 
     7#define OPS_PACKET_TO_TEXT_H 
    98 
    109#ifndef OPS_PACKET_H 
     
    2322    list_t known; 
    2423    list_t unknown; 
    25     } decoded_t; 
     24    } text_t; 
    2625 
    2726 
     
    3231    } bit_map_t; 
    3332 
    34 void decoded_init(decoded_t * decoded); 
    35 void decoded_free(decoded_t * decoded); 
     33void text_init(text_t * text); 
     34void text_free(text_t * text); 
    3635 
    37 decoded_t * decode_ss_preferred_compression(ops_ss_preferred_compression_t ss_preferred_compression); 
    38 char * decode_single_ss_preferred_compression(unsigned char octet); 
     36text_t * text_ss_preferred_compression(ops_ss_preferred_compression_t ss_preferred_compression); 
     37char * text_single_ss_preferred_compression(unsigned char octet); 
    3938 
    40 decoded_t * decode_ss_preferred_hash(ops_ss_preferred_hash_t ss_preferred_hash); 
    41 char * decode_single_ss_preferred_hash(unsigned char octet); 
     39text_t * text_ss_preferred_hash(ops_ss_preferred_hash_t ss_preferred_hash); 
     40char * text_single_ss_preferred_hash(unsigned char octet); 
    4241 
    43 decoded_t * decode_ss_preferred_ska(ops_ss_preferred_ska_t ss_preferred_ska); 
    44 char * decode_single_ss_preferred_ska(unsigned char octet); 
     42text_t * text_ss_preferred_ska(ops_ss_preferred_ska_t ss_preferred_ska); 
     43char * text_single_ss_preferred_ska(unsigned char octet); 
    4544 
    46 char *decode_ss_revocation_reason_code(unsigned char octet); 
     45char *text_ss_revocation_reason_code(unsigned char octet); 
    4746 
    48 decoded_t * decode_ss_features(ops_ss_features_t ss_features); 
    49 char * decode_single_ss_feature(unsigned char octet, bit_map_t *map); 
     47text_t * text_ss_features(ops_ss_features_t ss_features); 
     48char * text_single_ss_feature(unsigned char octet, bit_map_t *map); 
    5049 
    51 decoded_t *decode_ss_key_flags(ops_ss_key_flags_t ss_key_flags); 
    52 char *decode_single_ss_key_flag(unsigned char octet, bit_map_t *map); 
     50text_t *text_ss_key_flags(ops_ss_key_flags_t ss_key_flags); 
     51char *text_single_ss_key_flag(unsigned char octet, bit_map_t *map); 
    5352 
    54 decoded_t *decode_ss_key_server_prefs(ops_ss_key_server_prefs_t ss_key_server_prefs); 
    55 char *decode_single_ss_key_server_prefs(unsigned char octet, bit_map_t *map); 
     53text_t *text_ss_key_server_prefs(ops_ss_key_server_prefs_t ss_key_server_prefs); 
     54char *text_single_ss_key_server_prefs(unsigned char octet, bit_map_t *map); 
    5655 
    57 decoded_t *decode_ss_notation_data_flags(ops_ss_notation_data_t ss_notation_data); 
     56text_t *text_ss_notation_data_flags(ops_ss_notation_data_t ss_notation_data); 
    5857 
    5958/* vim:set textwidth=120: */ 
    6059/* vim:set ts=8: */ 
    6160 
    62 #endif /* OPS_PACKET_DECODE_H */ 
     61#endif /* OPS_PACKET_TO_TEXT_H */ 
  • openpgpsdk/trunk/src/Makefile.template

    r120 r126  
    1111LIBOBJS = packet-parse.o util.o openssl_crypto.o accumulate.o build.o \ 
    1212        memory.o fingerprint.o hash.o keyring.o signature.o compress.o \ 
    13         packet-decode.o create.o 
     13        packet-to-text.o create.o 
    1414 
    1515libops.a: $(LIBOBJS) 
  • openpgpsdk/trunk/src/packet-to-text.c

    r123 r126  
    1 /** \file packet-decode.c 
     1/** \file packet-to_text.c 
    22 * 
    33 * Creates printable text strings from packet contents 
     
    66 */ 
    77 
    8 #include "packet-decode.h" 
     8#include "packet-to-text.h" 
    99 
    1010#include <stdlib.h> 
     
    199199 
    200200 
    201 unsigned int process_octet_str(decoded_t * decoded, char * str, unsigned char octet) 
    202     { 
    203     if (str && !add_str(&decoded->known,str))  
     201unsigned int process_octet_str(text_t * text, char * str, unsigned char octet) 
     202    { 
     203    if (str && !add_str(&text->known,str))  
    204204        { 
    205205        /* value recognised, but there was a problem adding it to the list */ 
     
    216216           Ben? -- rachel */ 
    217217        sprintf(str,"0x%x",octet); 
    218         if (!add_str(&decoded->unknown,str)) 
     218        if (!add_str(&text->unknown,str)) 
    219219            return 0; 
    220220        } 
     
    222222    } 
    223223 
    224 unsigned int process_bitmap_str(decoded_t * decoded, char * str, unsigned char bit) 
    225     { 
    226     if (str && !add_str(&decoded->known,str))  
     224unsigned int process_bitmap_str(text_t * text, char * str, unsigned char bit) 
     225    { 
     226    if (str && !add_str(&text->known,str))  
    227227        { 
    228228        /* value recognised, but there was a problem adding it to the list */ 
     
    239239           Ben? -- rachel */ 
    240240        sprintf(str,"Unknown bit(%d)",bit); 
    241         if (!add_str(&decoded->unknown,str)) 
     241        if (!add_str(&text->unknown,str)) 
    242242            return 0; 
    243243        } 
     
    249249 */ 
    250250 
    251 void decoded_init(decoded_t * decoded
    252     { 
    253     list_init(&decoded->known); 
    254     list_init(&decoded->unknown); 
    255     } 
    256  
    257 void decoded_free(decoded_t * decoded
     251void text_init(text_t * text
     252    { 
     253    list_init(&text->known); 
     254    list_init(&text->unknown); 
     255    } 
     256 
     257void text_free(text_t * text
    258258    { 
    259259    /* Strings in "known" array will be constants, so don't free them */ 
    260     list_free(&decoded->known); 
     260    list_free(&text->known); 
    261261 
    262262    /* Strings in "unknown" array will be dynamically allocated, so do free them */ 
    263     list_free_strings(&decoded->unknown); 
    264     list_free(&decoded->unknown); 
    265  
    266     /* finally, free the decoded structure itself */ 
    267     free(decoded); 
     263    list_free_strings(&text->unknown); 
     264    list_free(&text->unknown); 
     265 
     266    /* finally, free the text structure itself */ 
     267    free(text); 
    268268    } 
    269269 
     
    272272 */ 
    273273 
    274 char * decode_ss_revocation_reason_code(unsigned char octet) 
     274char * text_ss_revocation_reason_code(unsigned char octet) 
    275275    { 
    276276    return(search_octet_map(octet,revocation_reason_code_map)); 
    277277    } 
    278278 
    279 char * decode_single_ss_preferred_compression(unsigned char octet) 
     279char * text_single_ss_preferred_compression(unsigned char octet) 
    280280    { 
    281281    return(search_octet_map(octet,compression_algorithm_map)); 
    282282    } 
    283283 
    284 decoded_t * decode_ss_preferred_compression(ops_ss_preferred_compression_t array) 
     284text_t * text_ss_preferred_compression(ops_ss_preferred_compression_t array) 
    285285    { 
    286286    /* this can be generalised further to handle any similar list -- rachel */ 
    287287 
    288     decoded_t * decoded=NULL; 
     288    text_t * text=NULL; 
    289289    char * str; 
    290290    int i=0; 
    291291 
    292     decoded=malloc(sizeof(decoded_t)); 
    293     if (!decoded
    294         return NULL; 
    295  
    296     decoded_init(decoded); 
     292    text=malloc(sizeof(text_t)); 
     293    if (!text
     294        return NULL; 
     295 
     296    text_init(text); 
    297297 
    298298    for ( i=0; i < array.len; i++) 
    299299        { 
    300         str=decode_single_ss_preferred_compression(array.data[i]); 
    301         if (!process_octet_str(decoded,str,array.data[i])) 
     300        str=text_single_ss_preferred_compression(array.data[i]); 
     301        if (!process_octet_str(text,str,array.data[i])) 
    302302            return NULL; 
    303303 
    304304        } 
    305305    /* All values have been added to either the known or the unknown list */ 
    306     return decoded
    307     } 
    308  
    309 char * decode_single_ss_preferred_hash(unsigned char octet) 
     306    return text
     307    } 
     308 
     309char * text_single_ss_preferred_hash(unsigned char octet) 
    310310    { 
    311311    return(search_octet_map(octet,hash_algorithm_map)); 
    312312    } 
    313313 
    314 decoded_t * decode_ss_preferred_hash(ops_ss_preferred_hash_t array) 
     314text_t * text_ss_preferred_hash(ops_ss_preferred_hash_t array) 
    315315    { 
    316316    /* this can be generalised further to handle any similar list -- rachel */ 
    317317 
    318     decoded_t * decoded=NULL; 
     318    text_t * text=NULL; 
    319319    char * str; 
    320320    int i=0; 
    321321 
    322     decoded=malloc(sizeof(decoded_t)); 
    323     if (!decoded
    324         return NULL; 
    325  
    326     decoded_init(decoded); 
     322    text=malloc(sizeof(text_t)); 
     323    if (!text
     324        return NULL; 
     325 
     326    text_init(text); 
    327327 
    328328    for ( i=0; i < array.len; i++) 
    329329        { 
    330         str=decode_single_ss_preferred_hash(array.data[i]); 
    331         if (!process_octet_str(decoded,str,array.data[i])) 
     330        str=text_single_ss_preferred_hash(array.data[i]); 
     331        if (!process_octet_str(text,str,array.data[i])) 
    332332            return NULL; 
    333333 
    334334        } 
    335335    /* All values have been added to either the known or the unknown list */ 
    336     return decoded
    337     } 
    338  
    339 char * decode_single_ss_preferred_ska(unsigned char octet) 
     336    return text
     337    } 
     338 
     339char * text_single_ss_preferred_ska(unsigned char octet) 
    340340    { 
    341341    return(search_octet_map(octet,symmetric_key_algorithm_map)); 
     
    345345 * Produce a structure containing human-readable textstrings 
    346346 * representing the recognised and unrecognised contents 
    347  * of this byte array. decode_fn() will be called on each octet in turn. 
     347 * of this byte array. text_fn() will be called on each octet in turn. 
    348348 * 
    349349 */  
    350350 
    351 static decoded_t *decode_bytearray(data_t *data,  
    352                               char *(*decode_fn)(unsigned char octet)) 
    353     { 
    354  
    355     decoded_t * decoded=NULL; 
     351static text_t *text_bytearray(data_t *data,  
     352                              char *(*text_fn)(unsigned char octet)) 
     353    { 
     354 
     355    text_t * text=NULL; 
    356356    char * str; 
    357357    int i=0; 
    358358 
    359     decoded=malloc(sizeof(decoded_t)); 
    360     if (!decoded
    361         return NULL; 
    362  
    363     decoded_init(decoded); 
     359    text=malloc(sizeof(text_t)); 
     360    if (!text
     361        return NULL; 
     362 
     363    text_init(text); 
    364364 
    365365    for ( i=0; i < data->len; i++) 
    366366        { 
    367         str=(*decode_fn)(data->contents[i]); 
    368         if (!process_octet_str(decoded,str,data->contents[i])) 
     367        str=(*text_fn)(data->contents[i]); 
     368        if (!process_octet_str(text,str,data->contents[i])) 
    369369            return NULL; 
    370370 
    371371        } 
    372372    /* All values have been added to either the known or the unknown list */ 
    373     return decoded
    374     } 
    375  
    376 decoded_t * decode_ss_preferred_ska(ops_ss_preferred_ska_t ss_preferred_ska) 
    377     { 
    378     return(decode_bytearray(&ss_preferred_ska.data,  
    379                        &decode_single_ss_preferred_ska)); 
    380     } 
    381  
    382 char * decode_single_ss_feature(unsigned char octet, bit_map_t * map) 
     373    return text
     374    } 
     375 
     376text_t * text_ss_preferred_ska(ops_ss_preferred_ska_t ss_preferred_ska) 
     377    { 
     378    return(text_bytearray(&ss_preferred_ska.data,  
     379                       &text_single_ss_preferred_ska)); 
     380    } 
     381 
     382char * text_single_ss_feature(unsigned char octet, bit_map_t * map) 
    383383    { 
    384384    return(search_bit_map(octet,map)); 
    385385    } 
    386386 
    387 /** decoded_t * decode_ss_features(ops_ss_features_t * ss_features) 
     387/** text_t * text_ss_features(ops_ss_features_t * ss_features) 
    388388*/ 
    389389 
    390 decoded_t * decode_ss_features(ops_ss_features_t ss_features) 
    391     { 
    392     decoded_t *decoded=NULL; 
     390text_t * text_ss_features(ops_ss_features_t ss_features) 
     391    { 
     392    text_t *text=NULL; 
    393393    char *str; 
    394394    int i=0, j=0; 
    395395    unsigned char mask, bit; 
    396396 
    397      decoded=malloc(sizeof(decoded_t)); 
    398     if (!decoded
    399         return NULL; 
    400  
    401     decoded_init(decoded); 
     397     text=malloc(sizeof(text_t)); 
     398    if (!text
     399        return NULL; 
     400 
     401    text_init(text); 
    402402 
    403403    for ( i=0; i < ss_features.len; i++) 
     
    408408            if (bit) 
    409409                { 
    410                 str=decode_single_ss_feature ( bit, ss_feature_map[i] ); 
    411                 if (!process_bitmap_str( decoded, str, bit)) 
     410                str=text_single_ss_feature ( bit, ss_feature_map[i] ); 
     411                if (!process_bitmap_str( text, str, bit)) 
    412412                    return NULL; 
    413413                } 
    414414            } 
    415415        } 
    416     return decoded
    417     } 
    418  
    419 /** char *decode_bit (unsigned char octet, bit_map_t *map) 
    420  */ 
    421  
    422 char * decode_bit(unsigned char octet, bit_map_t * map) 
     416    return text
     417    } 
     418 
     419/** char *text_bit (unsigned char octet, bit_map_t *map) 
     420 */ 
     421 
     422char * text_bit(unsigned char octet, bit_map_t * map) 
    423423    { 
    424424    return(search_bit_map(octet,map)); 
    425425    } 
    426426 
    427 /** decoded_t * decode_map (data_t *data, bit_map_t *map) 
     427/** text_t * text_map (data_t *data, bit_map_t *map) 
    428428*/ 
    429429 
    430 decoded_t * decode_map(data_t *data, bit_map_t **map) 
    431     { 
    432     decoded_t *decoded=NULL; 
     430text_t * text_map(data_t *data, bit_map_t **map) 
     431    { 
     432    text_t *text=NULL; 
    433433    char *str; 
    434434    int i=0, j=0; 
    435435    unsigned char mask, bit; 
    436436 
    437      decoded=malloc(sizeof(decoded_t)); 
    438     if (!decoded
    439         return NULL; 
    440  
    441     decoded_init(decoded); 
     437     text=malloc(sizeof(text_t)); 
     438    if (!text
     439        return NULL; 
     440 
     441    text_init(text); 
    442442 
    443443    for ( i=0; i < data->len; i++) 
     
    448448            if (bit) 
    449449                { 
    450                 str=decode_bit ( bit, map[i] ); 
    451                 if (!process_bitmap_str( decoded, str, bit)) 
     450                str=text_bit ( bit, map[i] ); 
     451                if (!process_bitmap_str( text, str, bit)) 
    452452                    return NULL; 
    453453                } 
    454454            } 
    455455        } 
    456     return decoded
    457     } 
    458  
    459 decoded_t * decode_ss_notation_data_flags(ops_ss_notation_data_t ss_notation_data) 
    460     { 
    461     return(decode_map(&ss_notation_data.flags,ss_notation_data_map)); 
    462     } 
    463  
    464 char * decode_single_ss_key_flag(unsigned char octet, bit_map_t * map) 
     456    return text
     457    } 
     458 
     459text_t * text_ss_notation_data_flags(ops_ss_notation_data_t ss_notation_data) 
     460    { 
     461    return(text_map(&ss_notation_data.flags,ss_notation_data_map)); 
     462    } 
     463 
     464char * text_single_ss_key_flag(unsigned char octet, bit_map_t * map) 
    465465    { 
    466466    return(search_bit_map(octet,map)); 
    467467    } 
    468468 
    469 decoded_t * decode_ss_key_flags(ops_ss_key_flags_t ss_key_flags) 
    470     { 
    471     decoded_t *decoded=NULL; 
     469text_t * text_ss_key_flags(ops_ss_key_flags_t ss_key_flags) 
     470    { 
     471    text_t *text=NULL; 
    472472    char *str; 
    473473    int i=0; 
    474474    unsigned char mask, bit; 
    475475 
    476      decoded=malloc(sizeof(decoded_t)); 
    477     if (!decoded
    478         return NULL; 
    479  
    480     decoded_init(decoded); 
     476     text=malloc(sizeof(text_t)); 
     477    if (!text
     478        return NULL; 
     479 
     480    text_init(text); 
    481481 
    482482    /* xxx - TBD: extend to handle multiple octets of bits - rachel */ 
     
    487487            if (bit) 
    488488                { 
    489                 str=decode_single_ss_key_flag ( bit, &ss_key_flags_map[0] ); 
    490                 if (!process_bitmap_str( decoded, str, bit)) 
     489                str=text_single_ss_key_flag ( bit, &ss_key_flags_map[0] ); 
     490                if (!process_bitmap_str( text, str, bit)) 
    491491                    return NULL; 
    492492                } 
    493493            } 
    494494/* xxx - must add error text if more than one octet. Only one currently specified -- rachel */ 
    495     return decoded
    496     } 
    497  
    498 char *decode_single_ss_key_server_prefs(unsigned char octet, bit_map_t *map) 
     495    return text
     496    } 
     497 
     498char *text_single_ss_key_server_prefs(unsigned char octet, bit_map_t *map) 
    499499    { 
    500500    return(search_bit_map(octet,map)); 
    501501    } 
    502502 
    503 decoded_t *decode_ss_key_server_prefs(ops_ss_key_server_prefs_t ss_key_server_prefs) 
    504     { 
    505     decoded_t *decoded=NULL; 
     503text_t *text_ss_key_server_prefs(ops_ss_key_server_prefs_t ss_key_server_prefs) 
     504    { 
     505    text_t *text=NULL; 
    506506    char *str; 
    507507    int i=0; 
    508508    unsigned char mask, bit; 
    509509 
    510     decoded=malloc(sizeof(decoded_t)); 
    511     if (!decoded
    512         return NULL; 
    513  
    514     decoded_init(decoded); 
     510    text=malloc(sizeof(text_t)); 
     511    if (!text
     512        return NULL; 
     513 
     514    text_init(text); 
    515515 
    516516    /* xxx - TBD: extend to handle multiple octets of bits - rachel */ 
     
    521521            if (bit) 
    522522                { 
    523                 str=decode_single_ss_key_server_prefs ( bit, &ss_key_server_prefs_map[0] ); 
    524                 if (!process_bitmap_str( decoded, str, bit)) 
     523                str=text_single_ss_key_server_prefs ( bit, &ss_key_server_prefs_map[0] ); 
     524                if (!process_bitmap_str( text, str, bit)) 
    525525                    return NULL; 
    526526                } 
    527527            } 
    528528/* xxx - must add error text if more than one octet. Only one currently specified -- rachel */ 
    529     return decoded
     529    return text
    530530    } 
    531531