Skip to content

Commit

Permalink
cast size_t to long long unsigned (#903)
Browse files Browse the repository at this point in the history
fix a few compiler warnings as well
  • Loading branch information
pjstevns committed Jul 4, 2011
1 parent 99a180e commit d04945c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
10 changes: 6 additions & 4 deletions src/dbmail-user.c
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,11 @@ int do_add(const char * const user,

if (db_createmailbox("INBOX", useridnr, &mailbox_idnr) < 0) {
qprintf("failed... removing user... ");
if (auth_delete_user(user))
if (auth_delete_user(user)) {
qprintf("failed also.\n");
else
} else {
qprintf("done.\n");
}
return -1;
}
qprintf("ok.\n");
Expand Down Expand Up @@ -708,10 +709,11 @@ int do_empty(u64_t useridnr)
fflush(stdout);

result = db_empty_mailbox(useridnr);
if (result != 0)
if (result != 0) {
qerrorf("Error. Please check the log.\n");
else
} else {
qprintf("Ok.\n");
}
} else {
GList *children = NULL;
u64_t owner_idnr;
Expand Down
2 changes: 1 addition & 1 deletion src/pop3.c
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,7 @@ int pop3(ClientSession_t *session, const char *buffer)
msg->virtual_messagestatus = MESSAGE_STATUS_SEEN;
if (! (s = db_get_message_lines(msg->realmessageid, -2, 0)))
return -1;
i = ci_write(ci, "+OK %llu octets\r\n%s", strlen(s), s);
i = ci_write(ci, "+OK %llu octets\r\n%s", (u64_t)strlen(s), s);
g_free(s);
return 1;
}
Expand Down

0 comments on commit d04945c

Please sign in to comment.