Skip to content

Commit

Permalink
lib-sieve: deprecated notify extension: Fixed various bool vs. int/po…
Browse files Browse the repository at this point in the history
…inter mixups.

Found with clang -Wstrict-bool.
  • Loading branch information
stephanbosch committed Oct 14, 2016
1 parent 348ab93 commit 4374156
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/lib-sieve/plugins/notify/cmd-notify.c
Expand Up @@ -283,12 +283,12 @@ static int cmd_notify_address_validate
if ( sieve_argument_is_string_literal(arg) ) {
string_t *address = sieve_ast_argument_str(arg);
const char *error;
bool result = FALSE;
int result;

T_BEGIN {
result = sieve_address_validate(address, &error);
result = ( sieve_address_validate(address, &error) ? 1 : -1 );

if ( !result ) {
if ( result <= 0 ) {
sieve_argument_validate_error(valdtr, arg,
"specified :options address '%s' is invalid for "
"the mailto notify method: %s",
Expand All @@ -299,7 +299,7 @@ static int cmd_notify_address_validate
return result;
}

return TRUE;
return 1;
}

static bool cmd_notify_validate
Expand Down

0 comments on commit 4374156

Please sign in to comment.