Changeset 5357:f3c705877ceb in roaraudio for libroar/hash.c


Ignore:
Timestamp:
12/15/11 18:13:47 (12 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

fixed some compiler warnings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libroar/hash.c

    r5284 r5357  
    8989 {ROAR_HT_ISBN13,      "ISBN13",      8   }, 
    9090 {ROAR_HT_ADLER32,     "ADLER32",     4   }, 
    91  {-1, NULL} 
     91 {-1, NULL, -1} 
    9292}; 
    9393 
     
    211211 } 
    212212 
    213  if ( !(slen == -1 || digestlen == slen) ) { 
     213 if ( !(slen == -1 || (ssize_t)digestlen == slen) ) { 
    214214  roar_err_set(ROAR_ERROR_INVAL); 
    215215  return -1; 
     
    410410 
    411411 algo = roar_ht2gcrypt_tested(algo); 
    412  if ( algo == -1 ) 
     412 if ( algo == (roar_hash_t)-1 ) 
    413413  return -1; 
    414414 
     
    447447 
    448448 len = roar_ht_digestlen(algo); 
    449  if ( len == -1 ) 
     449 if ( len == (size_t)-1 ) /* this is a hack to avoid len to be of type ssize_t which breaks following code */ 
    450450  return -1; 
    451451 
Note: See TracChangeset for help on using the changeset viewer.