Fixed return value in procedure

This commit is contained in:
EgorWeders 2024-08-21 06:42:49 +00:00
parent d772a7fe92
commit 18fa524480

View File

@ -207,7 +207,7 @@ static void add_filter_str(int proto, int port) {
char *new_filter = malloc(new_filter_size); char *new_filter = malloc(new_filter_size);
if (!new_filter) if (!new_filter)
return FALSE; return;
strcpy(new_filter, current_filter); strcpy(new_filter, current_filter);
if (proto == IPPROTO_UDP) if (proto == IPPROTO_UDP)
@ -225,7 +225,7 @@ static void add_ip_id_str(int id) {
char *addfilter = malloc(strlen(ipid) + 16); char *addfilter = malloc(strlen(ipid) + 16);
if (!addfilter) if (!addfilter)
return FALSE; return ;
sprintf(addfilter, ipid, id); sprintf(addfilter, ipid, id);
@ -248,7 +248,7 @@ static void add_maxpayloadsize_str(unsigned short maxpayload) {
char *addfilter = malloc(strlen(maxpayloadsize_str) + 16); char *addfilter = malloc(strlen(maxpayloadsize_str) + 16);
if (!addfilter) if (!addfilter)
return FALSE; return ;
sprintf(addfilter, maxpayloadsize_str, maxpayload); sprintf(addfilter, maxpayloadsize_str, maxpayload);