/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int * NEAP_OpenNEAPService(void)
{
int *__s;
int __fd;
int iVar1;
int *piVar2;
undefined4 local_18 [3];
local_18[0] = 1;
__s = (int *)malloc(0x24) //possible issue identified - semgrep
if (__s != (int *)0x0) {
memset(__s,0,0x24) //possible issue identified - semgrep
__fd = socket(2,1,0x11);
if ((-1 < __fd) && (iVar1 = setsockopt(__fd,0xffff,0x20,local_18,4), iVar1 != -1)) {
*__s = __fd;
return __s;
}
piVar2 = __errno_location();
fprintf(_stderr,"socket call failed: %d",*piVar2);
free(__s);
}
return (int *)0x0;
}