mirror of
https://github.com/yrutschle/sslh.git
synced 2026-10-22 18:12:10 +03:00
check asprintf return value
The current asprintf usage triggers many warnings like: sslh-main.c: In function 'print_usage': sslh-main.c:86:17: warning: ignoring return value of 'asprintf', declared with attribute warn_unused_result [-Wunused-result] Signed-off-by: Mike Frysinger <vapier@gentoo.org>
This commit is contained in:
1 parent
b8ea0699c4
commit
2d23cdc9f4
3 files changed
+10
-4
No files matched your search
@@ -63,7 +63,8 @@ int get_num_builtins(void) {
|
||||
/* Sets the protocol name to connect to in case of timeout */
|
||||
void set_ontimeout(const char* name)
|
||||
{
|
||||
asprintf(&on_timeout, "%s", name);
|
||||
int res = asprintf(&on_timeout, "%s", name);
|
||||
CHECK_RES_DIE(res, "asprintf");
|
||||
}
|
||||
|
||||
/* Returns the protocol to connect to in case of timeout;
|
||||
|
||||
Reference in new issue
Block a user