Fix enum compiler warnings (clang -Wenum-conversion)

This commit is contained in:
Andrew Bettison 2014-04-03 10:36:38 +10:30
parent f6f1752437
commit 76cce8fe7e
2 changed files with 3 additions and 3 deletions

View File

@ -722,7 +722,7 @@ void rhizome_direct_http_dispatch(rhizome_direct_sync_request *r)
struct rhizome_read read;
bzero(&read, sizeof read);
enum rhizome_bundle_status pstatus = rhizome_open_read(&read, &filehash);
enum rhizome_payload_status pstatus = rhizome_open_read(&read, &filehash);
switch (pstatus) {
case RHIZOME_PAYLOAD_STATUS_EMPTY:
case RHIZOME_PAYLOAD_STATUS_STORED:

View File

@ -607,7 +607,7 @@ enum rhizome_payload_status rhizome_import_payload_from_file(rhizome_manifest *m
// file payload is not in the store yet
if (rhizome_write_file(&write, filepath)){
rhizome_fail_write(&write);
return RHIZOME_BUNDLE_STATUS_ERROR;
return RHIZOME_PAYLOAD_STATUS_ERROR;
}
return rhizome_finish_write(&write);
@ -671,7 +671,7 @@ enum rhizome_payload_status rhizome_stat_payload_file(rhizome_manifest *m, const
return size ? RHIZOME_PAYLOAD_STATUS_NEW : RHIZOME_PAYLOAD_STATUS_EMPTY;
}
static enum rhizome_bundle_status rhizome_write_derive_key(rhizome_manifest *m, struct rhizome_write *write)
static enum rhizome_payload_status rhizome_write_derive_key(rhizome_manifest *m, struct rhizome_write *write)
{
if (m->payloadEncryption != PAYLOAD_ENCRYPTED)
return RHIZOME_PAYLOAD_STATUS_NEW;