Changeset 287

Show
Ignore:
Timestamp:
10/31/05 14:24:11
Author:
ben
Message:

Back out -Wdeclaration-after-statement - a more viable answer is -ansi, but
that will have to wait til I have more time.

Also fix _some_ of the problems -ansi introduces.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openpgpsdk/trunk/configure

    r284 r287  
    312312    if(getKnowledge('is_gcc')) { 
    313313        $flags='-Wall -Werror -W -g'; 
    314       my $v=getKnowledge('gcc_major'); 
    315       $flags.=' -Wdeclaration-after-statement' if $v >= 3; 
     314#     my $v=getKnowledge('gcc_major'); 
     315#     $flags.=' -Wdeclaration-after-statement' if $v >= 3; 
    316316    } 
    317317    return $flags; 
  • openpgpsdk/trunk/include/openpgpsdk/configure.h.template

    r250 r287  
    66#endif 
    77 
    8 // for silencing unused parameter warnings 
     8/* for silencing unused parameter warnings */ 
    99#define OPS_USED(x)     (x)=(x) 
  • openpgpsdk/trunk/include/openpgpsdk/packet-parse.h

    r282 r287  
    8787    ops_packet_reader_t *reader; /*!< the reader function to use to get the data to be parsed */ 
    8888    void *reader_arg; /*!< the args to pass to the reader function */ 
    89     // XXX: what do we do about offsets into compressed packets? 
     89    /* XXX: what do we do about offsets into compressed packets? */ 
    9090    unsigned position; /*!< the offset from the beginning (with this reader) */ 
    9191 
  • openpgpsdk/trunk/include/openpgpsdk/packet.h

    r274 r287  
    224224                                          length information, not at the same moment we create the packet tag structure. 
    225225                                          Only defined if #length_read is set. */  /* XXX: Ben, is this correct? */ 
    226     //    unsigned              length_read;    /*!< How much bytes of this packet we have read so far - for internal use 
    227     //                                    only. */ 
    228226    unsigned            position;       /*!< The position (within the current reader) of the packet */ 
    229227    } ops_ptag_t; 
     
    483481    ops_rsa_signature_t         rsa;    /*!< An RSA Signature */ 
    484482    ops_dsa_signature_t         dsa;    /*!< A DSA Signature */ 
    485     ops_elgamal_signature_t     elgamal; // deprecated 
     483    ops_elgamal_signature_t     elgamal; /* deprecated */ 
    486484    ops_unknown_signature_t     unknown; /* private or experimental */ 
    487485    } ops_signature_union_t; 
     
    504502    unsigned char               hash2[2];       /*!< high 2 bytes of hashed value - for quick test */ 
    505503    ops_signature_union_t       signature;      /*!< signature parameters */ 
    506     size_t                      v4_hashed_data_start; // only valid if accumulate is set 
     504    size_t                      v4_hashed_data_start; /* only valid if accumulate is set */ 
    507505    size_t                      v4_hashed_data_length; 
    508506    ops_boolean_t               creation_time_set:1; 
     
    620618    } ops_compression_type_t; 
    621619 
    622 // unlike most structures, this will feed its data as a stream 
    623 // to the application instead of directly including it 
     620/* unlike most structures, this will feed its data as a stream 
     621 * to the application instead of directly including it */ 
    624622/** ops_compressed_t */ 
    625623typedef struct 
  • openpgpsdk/trunk/src/armour.c

    r282 r287  
    230230    assert(body->data[0] == '\n'); 
    231231    assert(body->length == 1); 
    232     // and we don't send that one character, because its part of the trailer. 
    233     //    if(body->length) 
    234     //  CB(OPS_PTAG_CT_SIGNED_CLEARTEXT_BODY,&content); 
     232    /* don't send that one character, because its part of the trailer. */ 
    235233 
    236234    trailer->hash=hash; 
  • openpgpsdk/trunk/src/create.c

    r271 r287  
    8686    } 
    8787 
    88 // XXX: the general idea of _fast_ is that it doesn't copy stuff 
    89 // the safe (i.e. non _fast_) version will, and so will also need to 
    90 // be freed. 
     88/* XXX: the general idea of _fast_ is that it doesn't copy stuff 
     89 * the safe (i.e. non _fast_) version will, and so will also need to 
     90 * be freed. */ 
    9191 
    9292/** 
     
    118118                                       ops_create_options_t *opt) 
    119119    { 
    120     // \todo don't use strlen for UTF-8 string 
    121120    return ops_write_ptag(OPS_PTAG_CT_USER_ID,opt) 
    122121        && ops_write_length(strlen((char *)id->user_id),opt) 
     
    172171    } 
    173172 
    174 // Note that we support v3 keys here because they're needed for 
    175 // for verification - the writer doesn't allow them, though 
     173/* Note that we support v3 keys here because they're needed for 
     174 * for verification - the writer doesn't allow them, though */ 
    176175static int write_public_key_body(const ops_public_key_t *key, 
    177176                                  ops_create_options_t *opt) 
  • openpgpsdk/trunk/src/packet-show.c

    r280 r287  
    613613 * \todo add reference 
    614614 */ 
    615 // XXX: shouldn't this use show_all_octets_bits? 
     615/* XXX: shouldn't this use show_all_octets_bits? */ 
    616616ops_text_t *ops_showall_ss_features(ops_ss_features_t ss_features) 
    617617    { 
  • openpgpsdk/trunk/src/signature.c

    r273 r287  
    7171 
    7272    keysize=BN_num_bytes(rsa->n); 
    73     // RSA key can't be bigger than 65535 bits, so... 
     73    /* RSA key can't be bigger than 65535 bits, so... */ 
    7474    assert(keysize <= sizeof hashbuf); 
    7575    assert((unsigned)BN_num_bits(sig->sig) <= 8*sizeof sigbuf);