Skip to content

Commit

Permalink
Merge pull request #2195 from greenbone/get-credentials-missing-return-2
Browse files Browse the repository at this point in the history
Fix: missing return in handle_get_credentials
  • Loading branch information
a-h-abdelsalam authored May 21, 2024
2 parents 821d9d8 + 0fdd842 commit 41f2c16
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/gmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -12201,10 +12201,15 @@ handle_get_credentials (gmp_parser_t *gmp_parser, GError **error)
format = CREDENTIAL_FORMAT_NONE;

if (format == CREDENTIAL_FORMAT_ERROR)
SEND_TO_CLIENT_OR_FAIL
(XML_ERROR_SYNTAX ("get_credentials",
"Format attribute should"
" be 'key', 'rpm', 'deb', 'exe' or 'pem'"));
{
SEND_TO_CLIENT_OR_FAIL
(XML_ERROR_SYNTAX ("get_credentials",
"Format attribute should"
" be 'key', 'rpm', 'deb', 'exe' or 'pem'"));
get_credentials_data_reset (get_credentials_data);
set_client_state (CLIENT_AUTHENTIC);
return;
}

INIT_GET (credential, Credential);

Expand Down

0 comments on commit 41f2c16

Please sign in to comment.