LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/soapC.c
// Function: soap_put_PointerTowsa__ReferencePropertiesType
SOAP_FMAC4 soap_put_PointerTowsa__ReferencePropertiesType(struct soap *soap, struct wsa__ReferencePropertiesType *const*a, const char *tag, const char *type)
{
	register int id = soap_embed(soap, (void*)a, NULL, 0, tag, SOAP_TYPE_PointerTowsa__ReferencePropertiesType);
	if (soap_out_PointerTowsa__ReferencePropertiesType(soap, tag?tag:"wsa:ReferencePropertiesType", id, a, type))
		return soap->error;
	return soap_putindependent(soap);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
pushq $0xe
popq %r9
xorl %edx, %edx
xorl %ecx, %ecx
movq %r15, %r8
callq 0x162ad
testq %r15, %r15
leaq 0x138a9(%rip), %rsi     # 0x226aa
cmovneq %r15, %rsi
movq %rbx, %rdi
movl %eax, %edx
movq %r12, %rcx
movq %r14, %r8
callq 0xabfc
testl %eax, %eax
je 0xee2b
movl 0x1f274(%rbx), %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x8e7f
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/soapC.c
// Function: soap_put_string
SOAP_FMAC4 soap_put_string(struct soap *soap, char *const*a, const char *tag, const char *type)
{
	register int id = soap_embed(soap, (void*)a, NULL, 0, tag, SOAP_TYPE_string);
	if (soap_out_string(soap, tag?tag:"byte", id, a, type))
		return soap->error;
	return soap_putindependent(soap);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
pushq $0x4
popq %r9
xorl %edx, %edx
xorl %ecx, %ecx
movq %r15, %r8
callq 0x162ad
testq %r15, %r15
leaq 0x13600(%rip), %rsi     # 0x22543
cmovneq %r15, %rsi
movq %rbx, %rdi
movl %eax, %edx
movq %r12, %rcx
movq %r14, %r8
callq 0xa980
testl %eax, %eax
je 0xef6d
movl 0x1f274(%rbx), %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x8e7f
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_send_raw
SOAP_FMAC2
soap_send_raw(struct soap *soap, const char *s, size_t n)
{ if (!n)
    return SOAP_OK;
#ifndef WITH_LEANER
  if (soap->fpreparesend && (soap->mode & SOAP_IO) != SOAP_IO_STORE && (soap->mode & SOAP_IO_LENGTH) && (soap->error = soap->fpreparesend(soap, s, n)))
    return soap->error;
  if (soap->ffiltersend && (soap->error = soap->ffiltersend(soap, &s, &n)))
    return soap->error;
#endif
  if (soap->mode & SOAP_IO_LENGTH)
    soap->count += n;
  else if (soap->mode & SOAP_IO)
  { register size_t i = SOAP_BUFLEN - soap->bufidx;
    while (n >= i)
    { memcpy(soap->buf + soap->bufidx, s, i);
      soap->bufidx = SOAP_BUFLEN;
      if (soap_flush(soap))
        return soap->error;
      s += i;
      n -= i;
      i = SOAP_BUFLEN;
    }
    memcpy(soap->buf + soap->bufidx, s, n);
    soap->bufidx += n;
  }
  else
    return soap_flush_raw(soap, s, n);
  return SOAP_OK;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, 0x8(%rsp)
movq %rdx, (%rsp)
xorl %ebx, %ebx
testq %rdx, %rdx
je 0xf752
movq %rdi, %r14
movq 0xc098(%rdi), %rax
testq %rax, %rax
je 0xf69b
movl 0x4(%r14), %ecx
movl %ecx, %edi
andl $0x3, %edi
cmpl $0x2, %edi
sete %dil
testb $0x8, %cl
sete %cl
orb %dil, %cl
jne 0xf69b
movq %r14, %rdi
callq *%rax
movl %eax, 0x1f274(%r14)
testl %eax, %eax
jne 0xf750
movq 0xc0c0(%r14), %rax
testq %rax, %rax
je 0xf6c3
leaq 0x8(%rsp), %rsi
movq %rsp, %rdx
movq %r14, %rdi
callq *%rax
movl %eax, 0x1f274(%r14)
testl %eax, %eax
jne 0xf750
movl 0x4(%r14), %eax
testb $0x8, %al
jne 0xf732
testb $0x3, %al
je 0xf73f
movl $0x10000, %r15d         # imm = 0x10000
subq 0xc150(%r14), %r15
leaq 0xc198(%r14), %r13
movq (%rsp), %r12
movq 0xc150(%r14), %rdi
addq %r13, %rdi
movq 0x8(%rsp), %rsi
cmpq %r15, %r12
jb 0xf762
movq %r15, %rdx
callq 0x3220
movq $0x10000, 0xc150(%r14) # imm = 0x10000
movq %r14, %rdi
callq 0xf77c
testl %eax, %eax
jne 0xf773
addq %r15, 0x8(%rsp)
movq (%rsp), %r12
subq %r15, %r12
movq %r12, (%rsp)
movl $0x10000, %r15d         # imm = 0x10000
jmp 0xf6e7
movq (%rsp), %rax
addq %rax, 0xc170(%r14)
jmp 0xf752
movq 0x8(%rsp), %rsi
movq (%rsp), %rdx
movq %r14, %rdi
callq 0xf7ec
movl %eax, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %r12, %rdx
callq 0x3220
addq %r12, 0xc150(%r14)
jmp 0xf752
movl 0x1f274(%r14), %ebx
jmp 0xf752
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_flush_raw
SOAP_FMAC2
soap_flush_raw(struct soap *soap, const char *s, size_t n)
{ if ((soap->mode & SOAP_IO) == SOAP_IO_STORE)
  { register char *t;
    if (!(t = (char*)soap_push_block(soap, NULL, n)))
      return soap->error = SOAP_EOM;
    memcpy(t, s, n);
    return SOAP_OK;
  }
#ifndef WITH_LEANER
  if ((soap->mode & SOAP_IO) == SOAP_IO_CHUNK)
  { char t[16];
    sprintf(t, "\r\n%lX\r\n" + (soap->chunksize ? 0 : 2), (unsigned long)n);
    DBGMSG(SENT, t, strlen(t));
    if ((soap->error = soap->fsend(soap, t, strlen(t))))
      return soap->error;
    soap->chunksize += n;
  }
  DBGMSG(SENT, s, n);
#endif
  return soap->error = soap->fsend(soap, s, n);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movl 0x4(%rdi), %eax
andl $0x3, %eax
cmpl $0x3, %eax
je 0xf83e
cmpl $0x2, %eax
jne 0xf8a9
xorl %r12d, %r12d
movq %r14, %rdi
xorl %esi, %esi
movq %rbx, %rdx
callq 0xf8d4
testq %rax, %rax
je 0xf891
movq %rax, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x3220
jmp 0xf8c3
xorl %eax, %eax
cmpq $0x0, 0x1e5f8(%r14)
sete %al
leaq 0x1383e(%rip), %rcx     # 0x23090
leaq (%rcx,%rax,2), %rsi
movq %rsp, %r12
movq %r12, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x3310
movq 0xc028(%r14), %r13
movq %r12, %rdi
callq 0x3110
movq %r14, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq *%r13
movl %eax, 0x1f274(%r14)
testl %eax, %eax
je 0xf8a2
movl %eax, %r12d
jmp 0xf8c3
movl $0x14, 0x1f274(%r14)
pushq $0x14
popq %r12
jmp 0xf8c3
addq %rbx, 0x1e5f8(%r14)
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq *0xc028(%r14)
movl %eax, %r12d
movl %eax, 0x1f274(%r14)
movl %r12d, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_push_block
SOAP_FMAC1
void*
SOAP_FMAC2
soap_push_block(struct soap *soap, struct soap_blist *b, size_t n)
{ char *p;
  if (!b)
    b = soap->blist;
  DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Push block of %u bytes (%u bytes total)\n", (unsigned int)n, (unsigned int)b->size + (unsigned int)n));
  if (!(p = (char*)SOAP_MALLOC(soap, n + sizeof(char*) + sizeof(size_t))))
  { soap->error = SOAP_EOM;
    return NULL;
  }
  *(char**)p = b->ptr;
  *(size_t*)(p + sizeof(char*)) = n;
  b->ptr = p;
  b->size += n;
  return p + sizeof(char*) + sizeof(size_t);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
testq %rsi, %rsi
jne 0xf8ee
movq 0x90(%r15), %r14
leaq 0x10(%rbx), %rdi
callq 0x3240
testq %rax, %rax
je 0xf915
movq 0x8(%r14), %rcx
movq %rcx, (%rax)
movq %rbx, 0x8(%rax)
movq %rax, 0x8(%r14)
addq %rbx, 0x10(%r14)
addq $0x10, %rax
jmp 0xf922
movl $0x14, 0x1f274(%r15)
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_send3
SOAP_FMAC2
soap_send3(struct soap *soap, const char *s1, const char *s2, const char *s3)
{ if (soap_send(soap, s1)
   || soap_send(soap, s2))
    return soap->error;
  return soap_send(soap, s3);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r15
movq %rdi, %r14
callq 0xf928
testl %eax, %eax
jne 0xf9b1
movq %r14, %rdi
movq %r15, %rsi
callq 0xf928
testl %eax, %eax
je 0xf9be
movl 0x1f274(%r14), %eax
popq %rbx
popq %r14
popq %r15
retq
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0xf928
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_getchunkchar
static soap_wchar
soap_getchunkchar(struct soap *soap)
{ if (soap->bufidx < soap->buflen)
    return soap->buf[soap->bufidx++];
  soap->bufidx = 0;
  soap->buflen = soap->chunkbuflen = soap->frecv(soap, soap->buf, SOAP_BUFLEN);
  DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Read %u bytes from socket=%d/fd=%d\n", (unsigned int)soap->buflen, soap->socket, soap->recvfd));
  DBGMSG(RECV, soap->buf, soap->buflen);
  if (soap->buflen)
    return soap->buf[soap->bufidx++];
  return EOF;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0xc150(%rdi), %rax
cmpq 0xc158(%rdi), %rax
jae 0xfc89
leaq 0x1(%rax), %rcx
movq %rcx, 0xc150(%rbx)
leaq (%rbx,%rax), %r14
addq $0xc198, %r14           # imm = 0xC198
jmp 0xfcd1
andq $0x0, 0xc150(%rbx)
leaq 0xc198(%rbx), %r14
movl $0x10000, %edx          # imm = 0x10000
movq %rbx, %rdi
movq %r14, %rsi
callq *0xc030(%rbx)
movq %rax, 0x1e600(%rbx)
movq %rax, 0xc158(%rbx)
testq %rax, %rax
je 0xfcdd
movq 0xc150(%rbx), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0xc150(%rbx)
addq %rax, %r14
movsbl (%r14), %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
pushq $-0x1
popq %rax
jmp 0xfcd5
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_getchar
SOAP_FMAC2
soap_getchar(struct soap *soap)
{ register soap_wchar c;
  c = soap->ahead;
  if (c)
  { if (c != EOF)
      soap->ahead = 0;
    return c;
  }
  return soap_get1(soap);
}

// Assembly:
movl 0xc160(%rdi), %eax
cmpl $-0x1, %eax
je 0xffa5
pushq %rbx
movq %rdi, %rbx
testl %eax, %eax
jne 0xff81
movq 0xc150(%rbx), %rax
cmpq 0xc158(%rbx), %rax
jb 0xff91
movq %rbx, %rdi
callq 0xfce2
testl %eax, %eax
je 0xff8a
pushq $-0x1
popq %rax
jmp 0xffa4
andl $0x0, 0xc160(%rbx)
jmp 0xffa4
movq 0xc150(%rbx), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0xc150(%rbx)
movzbl 0xc198(%rbx,%rax), %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_code_int
SOAP_FMAC1
long
SOAP_FMAC2
soap_code_int(const struct soap_code_map *code_map, const char *str, long other)
{ if (code_map)
  { while (code_map->string)
    { if (!soap_tag_cmp(str, code_map->string)) /* case insensitive */
        return code_map->code;
      code_map++;
    }
  }
  return other;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
testq %rdi, %rdi
je 0x1001d
movq %rsi, %r15
movq %rdi, %r14
addq $0x8, %r14
movq (%r14), %rsi
testq %rsi, %rsi
je 0x1001d
movq %r15, %rdi
callq 0x10026
testl %eax, %eax
je 0x10019
addq $0x10, %r14
jmp 0xffff
movq -0x8(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_code_bits
SOAP_FMAC1
long
SOAP_FMAC2
soap_code_bits(const struct soap_code_map *code_map, const char *str)
{ register long bits = 0;
  if (code_map)
  { while (str && *str)
    { const struct soap_code_map *p;
      for (p = code_map; p->string; p++)
      { register size_t n = strlen(p->string);
        if (!strncmp(p->string, str, n) && soap_blank((soap_wchar)str[n]))
        { bits |= p->code;
          str += n;
          while (*str > 0 && *str <= 32)
            str++;
          break;
        }
      }
      if (!p->string)
        return 0;
    }
  }
  return bits;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
sete %al
testq %rsi, %rsi
sete %cl
orb %al, %cl
jne 0x101ba
movq %rsi, %rbx
movq %rdi, %r14
movb (%rsi), %al
addq $0x8, %r14
xorl %r15d, %r15d
testb %al, %al
je 0x101bd
movq %r14, %rbp
movq (%rbp), %r13
testq %r13, %r13
je 0x101ba
movq %r13, %rdi
callq 0x3110
movq %rax, %r12
movq %r13, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x3070
testl %eax, %eax
jne 0x10197
cmpb $0x20, (%rbx,%r12)
jbe 0x1019d
addq $0x10, %rbp
jmp 0x1016a
movq -0x8(%rbp), %rcx
addq %r12, %rbx
decq %rbx
movb 0x1(%rbx), %al
incq %rbx
leal -0x1(%rax), %edx
cmpb $0x20, %dl
jb 0x101a7
orq %rcx, %r15
jmp 0x10163
xorl %r15d, %r15d
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_code_list
SOAP_FMAC1
const char*
SOAP_FMAC2
soap_code_list(struct soap *soap, const struct soap_code_map *code_map, long code)
{ register char *t = soap->tmpbuf;
  if (code_map)
  { while (code_map->string)
    { if (code_map->code & code)
      { register const char *s = code_map->string;
        if (t != soap->tmpbuf)
          *t++ = ' ';
        while (*s && t < soap->tmpbuf + sizeof(soap->tmpbuf) - 1)
          *t++ = *s++;
        if (t == soap->tmpbuf + sizeof(soap->tmpbuf) - 1)
          break;
      }
      code_map++;
    }
  }
  *t = '\0';
  return soap->tmpbuf;
}

// Assembly:
leaq 0x1c598(%rdi), %rax
movq %rax, %r9
testq %rsi, %rsi
je 0x10243
movl $0x1c598, %ecx          # imm = 0x1C598
leaq (%rdi,%rcx), %r9
movq 0x8(%rsi), %r8
testq %r8, %r8
je 0x10243
testq %rdx, (%rsi)
je 0x10237
movl $0x1c598, %r10d         # imm = 0x1C598
cmpq $0x1c598, %rcx          # imm = 0x1C598
je 0x1020e
incq %rcx
movb $0x20, (%r9)
movq %rcx, %r10
movq %r10, %rcx
movb (%r8), %r9b
testb %r9b, %r9b
je 0x1022e
cmpq $0x1c996, %rcx          # imm = 0x1C996
jg 0x1022e
incq %r8
movb %r9b, (%rdi,%rcx)
incq %rcx
jmp 0x10211
cmpq $0x1c997, %rcx          # imm = 0x1C997
je 0x1023d
addq $0x10, %rsi
jmp 0x101e3
addq %rcx, %rdi
movq %rdi, %r9
movb $0x0, (%r9)
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_puthex
SOAP_FMAC2
soap_puthex(struct soap *soap, const unsigned char *s, int n)
{ char d[2];
  register int i;
#ifdef WITH_DOM
  if ((soap->mode & SOAP_XML_DOM) && soap->dom)
  { if (!(soap->dom->data = soap_s2hex(soap, s, NULL, n)))
      return soap->error;
    return SOAP_OK;
  }
#endif
  for (i = 0; i < n; i++)
  { register int m = *s++;
    d[0] = (char)((m >> 4) + (m > 159 ? '7' : '0'));
    m &= 0x0F;
    d[1] = (char)(m + (m > 9 ? '7' : '0'));
    if (soap_send_raw(soap, d, 2))
      return soap->error;
  }
  return SOAP_OK;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %r14d
movq %rsi, %r12
movq %rdi, %r15
xorl %eax, %eax
testl %edx, %edx
cmovlel %eax, %r14d
pushq $0x37
popq %rbx
pushq $0x30
popq %r13
xorl %ebp, %ebp
cmpl %ebp, %r14d
je 0x10c83
movb (%r12,%rbp), %al
movl %eax, %ecx
shrb $0x4, %cl
cmpb $-0x60, %al
movl %r13d, %edx
cmovael %ebx, %edx
addb %cl, %dl
movb %dl, 0x6(%rsp)
andb $0xf, %al
cmpb $0xa, %al
movl %r13d, %ecx
cmovael %ebx, %ecx
addb %al, %cl
movb %cl, 0x7(%rsp)
movq %r15, %rdi
leaq 0x6(%rsp), %rsi
pushq $0x2
popq %rdx
callq 0xf63c
testl %eax, %eax
jne 0x10c87
incq %rbp
jmp 0x10c3e
xorl %eax, %eax
jmp 0x10c8e
movl 0x1f274(%r15), %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_element_begin_in
SOAP_FMAC2
soap_element_begin_in(struct soap *soap, const char *tag, int nillable, const char *type)
{ if (!soap_peek_element(soap))
  { if (soap->other)
      return soap->error = SOAP_TAG_MISMATCH;
    if (tag && *tag == '-')
      return SOAP_OK;
	//printf("soap_element_begin_in %s %s\r\n", soap->tag, tag);
    if (!(soap->error = soap_match_tag(soap, soap->tag, tag)))
    { soap->peeked = 0;
      if (type && *soap->type && soap_match_tag(soap, soap->type, type))
        return soap->error = SOAP_TYPE;
      if (!nillable && soap->null && (soap->mode & SOAP_XML_STRICT))
        return soap->error = SOAP_NULL;
      if (soap->body)
        soap->level++;
      DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Begin element found (level=%u) '%s'='%s'\n", soap->level, soap->tag, tag?tag:SOAP_STR_EOS ));
    }
	//else
	//	printf("soap_element_begin_in %s %s failed=%d\r\n", soap->tag, tag,soap->error);
  }
  else if (soap->error == SOAP_NO_TAG && tag && *tag == '-')
    soap->error = SOAP_OK;
  return soap->error;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %r14
movl %edx, %ebp
movq %rsi, %r15
movq %rdi, %rbx
callq 0x11343
testl %eax, %eax
je 0x12025
testq %r15, %r15
je 0x120b5
cmpl $0x6, 0x1f274(%rbx)
jne 0x120b5
cmpb $0x2d, (%r15)
jne 0x120b5
andl $0x0, 0x1f274(%rbx)
jmp 0x120b5
cmpw $0x0, 0x1e598(%rbx)
je 0x1203e
movl $0x3, 0x1f274(%rbx)
pushq $0x3
popq %rax
jmp 0x120bb
testq %r15, %r15
je 0x1204b
xorl %eax, %eax
cmpb $0x2d, (%r15)
je 0x120bb
leaq 0x1c998(%rbx), %rsi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x13169
movl %eax, 0x1f274(%rbx)
testl %eax, %eax
jne 0x120b5
andw $0x0, 0x1e5f6(%rbx)
testq %r14, %r14
je 0x120a1
cmpb $0x0, 0x1d598(%rbx)
je 0x120a1
leaq 0x1d598(%rbx), %rsi
movq %rbx, %rdi
movq %r14, %rdx
callq 0x13169
testl %eax, %eax
je 0x120a1
movl $0x4, 0x1f274(%rbx)
pushq $0x4
jmp 0x1203b
testl %ebp, %ebp
je 0x120c6
cmpw $0x0, 0xc166(%rbx)
je 0x120b5
incl 0xc168(%rbx)
movl 0x1f274(%rbx), %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
cmpw $0x0, 0x1e5ec(%rbx)
je 0x120a5
testb $0x10, 0x5(%rbx)
je 0x120a5
movl $0x17, 0x1f274(%rbx)
pushq $0x17
jmp 0x1203b
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_dime_forward
SOAP_FMAC2
soap_dime_forward(struct soap *soap, unsigned char **ptr, int *size, char **id, char **type, char **options)
{ struct soap_xlist *xp;
  *ptr = NULL;
  *size = 0;
  *id = NULL;
  *type = NULL;
  *options = NULL;
  if (!*soap->href)
    return SOAP_OK;
  *id = soap_strdup(soap, soap->href);
  xp = (struct soap_xlist*)SOAP_MALLOC(soap, sizeof(struct soap_xlist));
  if (!xp)
    return soap->error = SOAP_EOM;
  xp->next = soap->xlist;
  xp->ptr = ptr;
  xp->size = size;
  xp->id = *id;
  xp->type = type;
  xp->options = options;
  soap->xlist = xp;
  return SOAP_OK;
}

// Assembly:
andq $0x0, (%rsi)
andl $0x0, (%rdx)
andq $0x0, (%rcx)
andq $0x0, (%r8)
andq $0x0, (%r9)
xorl %eax, %eax
cmpb $0x0, 0x1d198(%rdi)
je 0x1218f
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rcx, %rbx
movq %r8, %r12
movq %r9, %rbp
movq %rdi, %r13
movq %rsi, (%rsp)
leaq 0x1d198(%rdi), %rsi
callq 0x122d8
movq %rax, %r14
movq %rax, (%rbx)
pushq $0x30
popq %rdi
callq 0x3240
testq %rax, %rax
je 0x12173
movq 0x1f310(%r13), %rcx
movq %rcx, (%rax)
movq (%rsp), %rcx
movq %rcx, 0x8(%rax)
movq %r15, 0x10(%rax)
movq %r14, 0x18(%rax)
movq %r12, 0x20(%rax)
movq %rbp, 0x28(%rax)
movq %rax, 0x1f310(%r13)
xorl %eax, %eax
jmp 0x12181
movl $0x14, 0x1f274(%r13)
pushq $0x14
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_strdup
SOAP_FMAC1
char *
SOAP_FMAC2
soap_strdup(struct soap *soap, const char *s)
{ char *t = NULL;
  if (s && (t = (char*)soap_malloc(soap, strlen(s) + 1)))
    strcpy(t, s);
  return t;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0x12312
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x3110
leaq 0x1(%rax), %rsi
movq %r14, %rdi
callq 0x10ebe
testq %rax, %rax
je 0x12312
movq %rax, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x3080
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_wstrdup
SOAP_FMAC1
wchar_t *
SOAP_FMAC2
soap_wstrdup(struct soap *soap, const wchar_t *s)
{ wchar_t *t = NULL;
  if (s)
  { size_t n = 0;
    while (s[n])
      n++;
    if ((t = (wchar_t*)soap_malloc(soap, sizeof(wchar_t)*(n+1))))
      memcpy(t, s, sizeof(wchar_t)*(n+1));
  }
  return t;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0x12358
movq %rsi, %rbx
xorl %r14d, %r14d
cmpl $0x0, (%rbx,%r14)
leaq 0x4(%r14), %r14
jne 0x1232b
movq %r14, %rsi
callq 0x10ebe
testq %rax, %rax
je 0x12358
movq %rax, %rdi
movq %rbx, %rsi
movq %r14, %rdx
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x3220
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_pop_block
SOAP_FMAC2
soap_pop_block(struct soap *soap, struct soap_blist *b)
{ char *p;
  if (!b)
    b = soap->blist;
  if (!b->ptr)
    return;
  DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Pop block\n"));
  p = b->ptr;
  b->size -= *(size_t*)(p + sizeof(char*));
  b->ptr = *(char**)p;
  SOAP_FREE(soap, p);
}

// Assembly:
testq %rsi, %rsi
jne 0x123a5
movq 0x90(%rdi), %rsi
movq 0x8(%rsi), %rdi
testq %rdi, %rdi
je 0x123c2
movq 0x8(%rdi), %rax
subq %rax, 0x10(%rsi)
movq (%rdi), %rax
movq %rax, 0x8(%rsi)
jmp 0x3030
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_size_block
SOAP_FMAC2
soap_size_block(struct soap *soap, struct soap_blist *b, size_t n)
{ if (!b)
    b = soap->blist;
  if (b->ptr)
  { b->size -= *(size_t*)(b->ptr + sizeof(char*)) - n;
    *(size_t*)(b->ptr + sizeof(char*)) = n;
  }
  return b->size;
}

// Assembly:
testq %rsi, %rsi
jne 0x125f7
movq 0x90(%rdi), %rsi
movq 0x8(%rsi), %rax
testq %rax, %rax
je 0x1260f
movq %rdx, %rcx
subq 0x8(%rax), %rcx
addq %rcx, 0x10(%rsi)
movq %rdx, 0x8(%rax)
movq 0x10(%rsi), %rax
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_next_block
SOAP_FMAC1
char*
SOAP_FMAC2
soap_next_block(struct soap *soap, struct soap_blist *b)
{ char *p;
  if (!b)
    b = soap->blist;
  p = b->ptr;
  if (p)
  { DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Next block\n"));
    b->ptr = *(char**)p;
    SOAP_FREE(soap, p);
    if (b->ptr)
      return b->ptr + sizeof(char*) + sizeof(size_t);
  }
  return NULL;
}

// Assembly:
pushq %rbx
movq %rsi, %rbx
testq %rsi, %rsi
jne 0x12655
movq 0x90(%rdi), %rbx
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x1267b
movq (%rdi), %rax
movq %rax, 0x8(%rbx)
callq 0x3030
movq 0x8(%rbx), %rcx
leaq 0x10(%rcx), %rax
testq %rcx, %rcx
cmoveq %rcx, %rax
jmp 0x1267d
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_putsizesoffsets
SOAP_FMAC1
char *
SOAP_FMAC2
soap_putsizesoffsets(struct soap *soap, const char *type, const int *size, const int *offset, int dim)
{ int i;
  if (!type)
    return NULL;
  if (soap->version == 2)
  { sprintf(soap->type, "%s[%d", type, size[0]);
    for (i = 1; i < dim; i++)
      sprintf(soap->type + strlen(soap->type), " %d", size[i]);
  }
  else
  { if (offset)
    { sprintf(soap->type, "%s[%d", type, size[0] + offset[0]);
      for (i = 1; i < dim; i++)
        sprintf(soap->type + strlen(soap->type), ",%d", size[i] + offset[i]);
    }
    else
    { sprintf(soap->type, "%s[%d", type, size[0]);
      for (i = 1; i < dim; i++)
        sprintf(soap->type + strlen(soap->type), ",%d", size[i]);
    }
    strcat(soap->type, "]");
  }
  return soap->type;
}

// Assembly:
testq %rsi, %rsi
je 0x1294b
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %ebp
movq %rdx, %r14
movq %rsi, %rdx
cmpw $0x2, 0x2(%rdi)
movq %rdi, (%rsp)
jne 0x1294e
leaq 0x1d598(%rdi), %r15
movl (%r14), %ecx
leaq 0x10799(%rip), %rsi     # 0x230a4
movq %r15, %rdi
xorl %eax, %eax
callq 0x3310
movslq %ebp, %rbx
pushq $0x1
popq %r13
leaq 0x1170c(%rip), %r12     # 0x2402f
cmpq %rbx, %r13
jge 0x12a03
movq %r15, %rdi
callq 0x3110
leaq (%rax,%r15), %rdi
movl (%r14,%r13,4), %edx
movq %r12, %rsi
xorl %eax, %eax
callq 0x3310
incq %r13
jmp 0x12923
xorl %eax, %eax
retq
movq %rcx, %r12
leaq 0x1d598(%rdi), %r15
movl (%r14), %ecx
testq %r12, %r12
je 0x129aa
addl (%r12), %ecx
leaq 0x10739(%rip), %rsi     # 0x230a4
movq %r15, %rdi
xorl %eax, %eax
callq 0x3310
movslq %ebp, %rbp
pushq $0x1
popq %rbx
leaq 0x10728(%rip), %r13     # 0x230aa
cmpq %rbp, %rbx
jge 0x129ed
movq %r15, %rdi
callq 0x3110
leaq (%rax,%r15), %rdi
movl (%r12,%rbx,4), %edx
addl (%r14,%rbx,4), %edx
movq %r13, %rsi
xorl %eax, %eax
callq 0x3310
incq %rbx
jmp 0x12982
leaq 0x106f3(%rip), %rsi     # 0x230a4
movq %r15, %rdi
xorl %eax, %eax
callq 0x3310
movslq %ebp, %rbx
pushq $0x1
popq %r13
leaq 0x106e1(%rip), %r12     # 0x230aa
cmpq %rbx, %r13
jge 0x129ed
movq %r15, %rdi
callq 0x3110
leaq (%rax,%r15), %rdi
movl (%r14,%r13,4), %edx
movq %r12, %rsi
xorl %eax, %eax
callq 0x3310
incq %r13
jmp 0x129c9
movq %r15, %rdi
callq 0x3110
movq (%rsp), %rcx
movw $0x5d, 0x1d598(%rcx,%rax)
movq (%rsp), %rax
addq $0x1d598, %rax          # imm = 0x1D598
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_putoffsets
SOAP_FMAC1
char *
SOAP_FMAC2
soap_putoffsets(struct soap *soap, const int *offset, int dim)
{ register int i;
  sprintf(soap->arrayOffset, "[%d", offset[0]);
  for (i = 1; i < dim; i++)
    sprintf(soap->arrayOffset + strlen(soap->arrayOffset), ",%d", offset[i]);
  strcat(soap->arrayOffset, "]");
  return soap->arrayOffset;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
addq $0x1e198, %rbx          # imm = 0x1E198
movl (%rsi), %edx
leaq 0x10652(%rip), %rsi     # 0x230a6
movq %rbx, %rdi
xorl %eax, %eax
callq 0x3310
movslq %ebp, %r12
pushq $0x1
popq %r13
leaq 0x1063e(%rip), %r15     # 0x230aa
movq %rbx, %rdi
cmpq %r12, %r13
jge 0x12a90
callq 0x3110
leaq (%rax,%rbx), %rdi
movl (%r14,%r13,4), %edx
movq %r15, %rsi
xorl %eax, %eax
callq 0x3310
incq %r13
jmp 0x12a6c
callq 0x3110
movw $0x5d, (%rbx,%rax)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_size
SOAP_FMAC2
soap_size(const int *size, int dim)
{ register int i, n = size[0];
  for (i = 1; i < dim; i++)
    n *= size[i];
  return n;
}

// Assembly:
movl (%rdi), %eax
movslq %esi, %rcx
pushq $0x1
popq %rdx
cmpq %rcx, %rdx
jge 0x12ac3
imull (%rdi,%rdx,4), %eax
incq %rdx
jmp 0x12ab5
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_getoffsets
SOAP_FMAC2
soap_getoffsets(const char *attr, const int *size, int *offset, int dim)
{ register int i, j = 0;
  if (offset)
    for (i = 0; i < dim && attr && *attr; i++)
    { attr++;
      j *= size[i];
      j += offset[i] = (int)soap_strtol(attr, NULL, 10);
      attr = strchr(attr, ',');
    }
  else
    for (i = 0; i < dim && attr && *attr; i++)
    { attr++;
      j *= size[i];
      j += (int)soap_strtol(attr, NULL, 10);
      attr = strchr(attr, ',');
    }
  return j;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movslq %ecx, %r12
testq %rdx, %rdx
je 0x12b23
movq %rdx, %r15
xorl %r13d, %r13d
xorl %ebp, %ebp
cmpq %r12, %r13
jge 0x12b69
testq %r14, %r14
je 0x12b69
cmpb $0x0, (%r14)
je 0x12b69
incq %r14
imull (%rbx,%r13,4), %ebp
movq %r14, %rdi
xorl %esi, %esi
pushq $0xa
popq %rdx
callq 0x3210
movl %eax, (%r15,%r13,4)
addl %eax, %ebp
movq %r14, %rdi
pushq $0x2c
popq %rsi
callq 0x3130
movq %rax, %r14
incq %r13
jmp 0x12ae5
xorl %r15d, %r15d
xorl %ebp, %ebp
cmpq %r12, %r15
jge 0x12b69
testq %r14, %r14
je 0x12b69
cmpb $0x0, (%r14)
je 0x12b69
incq %r14
imull (%rbx,%r15,4), %ebp
movq %r14, %rdi
xorl %esi, %esi
pushq $0xa
popq %rdx
callq 0x3210
movq %rax, %r13
addl %ebp, %r13d
movq %r14, %rdi
pushq $0x2c
popq %rsi
callq 0x3130
movq %rax, %r14
incq %r15
movl %r13d, %ebp
jmp 0x12b28
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_getsizes
SOAP_FMAC2
soap_getsizes(const char *attr, int *size, int dim)
{ register int i, k, n;
  if (!*attr)
    return -1;
  i = (int)strlen(attr);
  n = 1;
  do
  { for (i = i-1; i >= 0; i--)
      if (attr[i] == '[' || attr[i] == ',' || attr[i] == ' ')
        break;
    k = (int)soap_strtol(attr + i + 1, NULL, 10);
    n *= size[--dim] = k;
    if (k < 0 || n > SOAP_MAXARRAYSIZE)
      return -1;
  } while (i >= 0 && attr[i] != '[');
  return n;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, (%rsp)
cmpb $0x0, (%rdi)
je 0x12d2d
movl %edx, %ebp
movq %rdi, %r14
callq 0x3110
movq %rax, %rbx
movslq %ebp, %r13
pushq $0x1
popq %rbp
movabsq $0x800000000001001, %rsi # imm = 0x800000000001001
movl %ebx, %eax
movl %ebx, %ecx
sarl $0x1f, %ecx
andl %ebx, %ecx
decl %ecx
decq %rax
movl %ebx, %r12d
testl %ebx, %ebx
jle 0x12cd6
movl %eax, %edx
movzbl (%r14,%rdx), %edx
leal -0x1(%r12), %ebx
decq %rax
addl $-0x20, %edx
cmpl $0x3b, %edx
ja 0x12cb0
btq %rdx, %rsi
jae 0x12cb0
jmp 0x12cd8
movl %ecx, %ebx
movslq %ebx, %r15
leaq (%r14,%r15), %rdi
incq %rdi
xorl %esi, %esi
pushq $0xa
popq %rdx
callq 0x3210
imull %eax, %ebp
testl %eax, %eax
sets %dl
cmpl $0xf4241, %ebp          # imm = 0xF4241
setge %cl
orb %dl, %cl
movq (%rsp), %rdx
movl %eax, -0x4(%rdx,%r13,4)
testl %r12d, %r12d
jle 0x12d32
testb %cl, %cl
jne 0x12d32
addq %r14, %r15
decq %r13
cmpb $0x5b, (%r15)
movabsq $0x800000000001001, %rsi # imm = 0x800000000001001
jne 0x12ca2
jmp 0x12d3a
pushq $-0x1
popq %rbp
jmp 0x12d3a
testb %cl, %cl
pushq $-0x1
popq %rax
cmovnel %eax, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_getposition
SOAP_FMAC2
soap_getposition(const char *attr, int *pos)
{ register int i, n;
  if (!*attr)
    return -1;
  n = 0;
  i = 1;
  do
  { pos[n++] = (int)soap_strtol(attr + i, NULL, 10);
    while (attr[i] && attr[i] != ',' && attr[i] != ']')
      i++;
    if (attr[i] == ',')
      i++;
  } while (n < SOAP_MAXDIMS && attr[i] && attr[i] != ']');
  return n;
}

// Assembly:
cmpb $0x0, (%rdi)
je 0x12dcb
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
pushq $0x1
popq %rbp
xorl %r13d, %r13d
pushq $0xa
popq %r15
movslq %ebp, %r12
addq %r14, %r12
movq %r12, %rdi
xorl %esi, %esi
movl %r15d, %edx
callq 0x3210
leaq 0x1(%r13), %rcx
movl %eax, (%rbx,%r13,4)
movl %ebp, %eax
movzbl (%r12), %edx
testl %edx, %edx
je 0x12da2
cmpl $0x2c, %edx
je 0x12da2
cmpl $0x5d, %edx
je 0x12da2
incl %eax
incq %r12
jmp 0x12d88
cmpq $0xf, %r13
je 0x12dcf
xorl %ebp, %ebp
cmpb $0x2c, %dl
sete %bpl
addl %eax, %ebp
movslq %ebp, %rax
movzbl (%r14,%rax), %eax
cmpl $0x5d, %eax
je 0x12dc7
movq %rcx, %r13
testl %eax, %eax
jne 0x12d6b
movl %ecx, %eax
jmp 0x12dd2
pushq $-0x1
popq %rax
retq
pushq $0x10
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_match_namespace
SOAP_FMAC2
soap_match_namespace(struct soap *soap, const char *id1, const char *id2, size_t n1, size_t n2)
{ register struct soap_nlist *np = soap->nlist;
  const char *s;
  while (np && (strncmp(np->id, id1, n1) || np->id[n1]))
    np = np->next;
  if (np)
  { if (!(soap->mode & SOAP_XML_IGNORENS))
      if (np->index < 0
       || ((s = soap->local_namespaces[np->index].id) && (strncmp(s, id2, n2) || (s[n2] && s[n2] != '_'))))
        return SOAP_NAMESPACE;
    return SOAP_OK;
  }
  if (n1 == 0)
    return (soap->mode & SOAP_XML_IGNORENS) ? SOAP_OK : SOAP_NAMESPACE;
  if ((n1 == 3 && n1 == n2 && !strncmp(id1, "xml", 3) && !strncmp(id1, id2, 3))
   || (soap->mode & SOAP_XML_IGNORENS))
    return SOAP_OK;
  return soap->error = SOAP_SYNTAX_ERROR;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r8, %r15
movq %rcx, %r13
movq %rdx, (%rsp)
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x88(%rdi), %r14
movq (%r14), %r14
testq %r14, %r14
je 0x1302d
leaq 0x18(%r14), %rbp
movq %rbp, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x3070
testl %eax, %eax
jne 0x12fa0
cmpb $0x0, (%rbp,%r13)
jne 0x12fa0
xorl %eax, %eax
testb $0x40, 0x5(%rbx)
jne 0x1308d
movswq 0xc(%r14), %rcx
pushq $0x9
popq %rbp
testq %rcx, %rcx
js 0x1309c
movq 0x80(%rbx), %rdx
shlq $0x5, %rcx
movq (%rdx,%rcx), %rbx
testq %rbx, %rbx
je 0x1308d
movq %rbx, %rdi
movq (%rsp), %rsi
movq %r15, %rdx
callq 0x3070
movl %eax, %ecx
movl %ebp, %eax
testl %ecx, %ecx
jne 0x1308d
movb (%rbx,%r15), %al
xorl %ecx, %ecx
cmpb $0x5f, %al
setne %cl
xorl %edx, %edx
testb %al, %al
leal (%rcx,%rcx,8), %eax
cmovel %edx, %eax
jmp 0x1308d
cmpq $0x3, %r13
je 0x13046
testq %r13, %r13
jne 0x13076
xorl %eax, %eax
testb $0x40, 0x5(%rbx)
sete %al
leal (%rax,%rax,8), %eax
jmp 0x1308d
cmpq $0x3, %r15
jne 0x13076
cmpb $0x78, (%r12)
jne 0x13076
cmpb $0x6d, 0x1(%r12)
jne 0x13076
cmpb $0x6c, 0x2(%r12)
jne 0x13076
pushq $0x3
popq %rdx
movq %r12, %rdi
movq (%rsp), %rsi
callq 0x3070
testl %eax, %eax
je 0x1308b
testb $0x40, 0x5(%rbx)
jne 0x1308b
movl $0x5, 0x1f274(%rbx)
pushq $0x5
popq %rax
jmp 0x1308d
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %ebp, %eax
jmp 0x1308d
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: tcp_error
static const char*
tcp_error(struct soap *soap)
{ register const char *msg = NULL;
  switch (soap->errmode)
  { case 0:
      msg = soap_strerror(soap);
      break;
    case 1:
      msg = "WSAStartup failed";
      break;
    case 2:
    {
#ifndef WITH_LEAN
      msg = soap_code_str(h_error_codes, soap->errnum);
      if (!msg)
#endif
      { sprintf(soap->msgbuf, "TCP/UDP IP error %d", soap->errnum);
        msg = soap->msgbuf;
      }
    }
  }
  return msg;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0x1f278(%rdi), %eax
cmpl $0x2, %eax
je 0x13623
cmpl $0x1, %eax
je 0x1361a
testl %eax, %eax
jne 0x1365c
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x213f7
leaq 0x10d5c(%rip), %rax     # 0x2437d
jmp 0x1365e
movl 0x1f27c(%rbx), %ebp
movslq %ebp, %rsi
leaq 0x1f4dd(%rip), %rdi     # 0x32b10
callq 0x1011d
testq %rax, %rax
jne 0x1365e
addq $0x1c198, %rbx          # imm = 0x1C198
leaq 0x10d44(%rip), %rsi     # 0x2438f
movq %rbx, %rdi
movl %ebp, %edx
xorl %eax, %eax
callq 0x3310
movq %rbx, %rax
jmp 0x1365e
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_closesock
SOAP_FMAC2
soap_closesock(struct soap *soap)
{ register int status = soap->error;
#ifndef WITH_LEANER
  if (status) /* close on error: attachment state is not to be trusted */
  { soap->mime.first = NULL;
    soap->mime.last = NULL;
    soap->dime.first = NULL;
    soap->dime.last = NULL;
  }
#endif
  if (soap->fdisconnect && (soap->error = soap->fdisconnect(soap)))
    return soap->error;
  if (status == SOAP_EOF || status == SOAP_TCP_ERROR || status == SOAP_SSL_ERROR || !soap->keep_alive)
  { if (soap->fclose && (soap->error = soap->fclose(soap)))
      return soap->error;
    soap->keep_alive = 0;
  }
#ifdef WITH_ZLIB
  if (soap->zlib_state == SOAP_ZLIB_DEFLATE)
    deflateEnd(soap->d_stream);
  else if (soap->zlib_state == SOAP_ZLIB_INFLATE)
    inflateEnd(soap->d_stream);
  soap->zlib_state = SOAP_ZLIB_NONE;
#endif
  return soap->error = status;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl 0x1f274(%rdi), %ebx
testl %ebx, %ebx
je 0x13689
xorps %xmm0, %xmm0
movups %xmm0, 0x1f2d8(%r14)
movups %xmm0, 0x1f300(%r14)
movq 0xbff8(%r14), %rax
testq %rax, %rax
je 0x136a5
movq %r14, %rdi
callq *%rax
movl %eax, 0x1f274(%r14)
testl %eax, %eax
jne 0x136d3
leal 0x1(%rbx), %eax
cmpl $0x1f, %eax
ja 0x136e2
movl $0xa0000001, %ecx       # imm = 0xA0000001
btl %eax, %ecx
jae 0x136e2
movq 0xc020(%r14), %rax
testq %rax, %rax
je 0x136d7
movq %r14, %rdi
callq *%rax
movl %eax, 0x1f274(%r14)
testl %eax, %eax
je 0x136d7
movl %eax, %ebx
jmp 0x136f4
andw $0x0, 0x1f22c(%r14)
jmp 0x136ed
cmpw $0x0, 0x1f22c(%r14)
je 0x136b7
movl %ebx, 0x1f274(%r14)
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_poll
SOAP_FMAC2
soap_poll(struct soap *soap)
{
#ifndef WITH_LEAN
  register int r;
  if (soap_valid_socket(soap->socket))
  { r = tcp_select(soap, soap->socket, SOAP_TCP_SELECT_ALL, 0);
    if (r > 0 && (r & SOAP_TCP_SELECT_ERR))
      r = -1;
  }
  else if (soap_valid_socket(soap->master))
    r = tcp_select(soap, soap->master, SOAP_TCP_SELECT_SND, 0);
  else
    return SOAP_OK; /* OK when no socket! */
  if (r > 0)
  {
#ifdef WITH_OPENSSL
    if (soap->imode & SOAP_ENC_SSL)
    {
      if (soap_valid_socket(soap->socket)
       && (r & SOAP_TCP_SELECT_SND)
       && (!(r & SOAP_TCP_SELECT_RCV)
        || SSL_peek(soap->ssl, soap->tmpbuf, 1) > 0))
        return SOAP_OK;
    }
    else
#endif
      if (soap_valid_socket(soap->socket)
       && (r & SOAP_TCP_SELECT_SND)
       && (!(r & SOAP_TCP_SELECT_RCV)
        || recv(soap->socket, soap->tmpbuf, 1, MSG_PEEK) > 0))
        return SOAP_OK;
  }
  else if (r < 0)
  { if ((soap_valid_socket(soap->master) || soap_valid_socket(soap->socket)) && soap_socket_errno(soap->master) != SOAP_EINTR)
    { soap_set_receiver_error(soap, tcp_error(soap), "select failed in soap_poll()", SOAP_TCP_ERROR);
      return soap->error = SOAP_TCP_ERROR;
    }
  }
  DBGLOG(TEST,SOAP_MESSAGE(fdebug, "Polling: other end down on socket=%d select=%d\n", soap->socket, r));
  return SOAP_EOF;
#else
  return SOAP_OK;
#endif
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0xc134(%rdi), %esi
cmpl $-0x1, %esi
je 0x13726
pushq $0x7
popq %rdx
movq %rbx, %rdi
xorl %ecx, %ecx
callq 0x137d1
testl %eax, %eax
jle 0x13776
testb $0x4, %al
je 0x13742
jmp 0x1377a
movl 0xc130(%rbx), %esi
cmpl $-0x1, %esi
je 0x137a2
pushq $0x2
popq %rdx
movq %rbx, %rdi
xorl %ecx, %ecx
callq 0x137d1
testl %eax, %eax
jle 0x13776
movl 0xc134(%rbx), %edi
cmpl $-0x1, %edi
je 0x13796
movl %eax, %ecx
andl $0x2, %ecx
je 0x13796
xorl %ebp, %ebp
testb $0x1, %al
je 0x13799
addq $0x1c598, %rbx          # imm = 0x1C598
pushq $0x1
popq %rdx
pushq $0x2
popq %rcx
movq %rbx, %rsi
callq 0x3040
testq %rax, %rax
jg 0x13799
jmp 0x13796
testl %eax, %eax
jns 0x13796
cmpl $-0x1, 0xc130(%rbx)
jne 0x1378c
cmpl $-0x1, 0xc134(%rbx)
je 0x13796
callq 0x3050
cmpl $0x4, (%rax)
jne 0x137a6
pushq $-0x1
popq %rbp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
xorl %ebp, %ebp
jmp 0x13799
movq %rbx, %rdi
callq 0x135f2
leaq 0xfa5f(%rip), %rdx      # 0x23214
pushq $0x1c
popq %rbp
movq %rbx, %rdi
movq %rax, %rsi
movl %ebp, %ecx
callq 0x135cb
movl $0x1c, 0x1f274(%rbx)
jmp 0x13799
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_free_temp
SOAP_FMAC2
soap_free_temp(struct soap *soap)
{ register struct soap_attribute *tp, *tq;
  register struct Namespace *ns;
  soap_free_ns(soap);
  DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free any remaining temp blocks\n"));
  while (soap->blist)
    soap_end_block(soap, NULL);
  DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free attribute storage\n"));
  for (tp = soap->attributes; tp; tp = tq)
  { tq = tp->next;
    if (tp->value)
      SOAP_FREE(soap, tp->value);
    SOAP_FREE(soap, tp);
  }
  soap->attributes = NULL;
#ifdef WITH_FAST
  if (soap->labbuf)
    SOAP_FREE(soap, soap->labbuf);
  soap->labbuf = NULL;
  soap->lablen = 0;
  soap->labidx = 0;
#endif
  ns = soap->local_namespaces;
  if (ns)
  { for (; ns->id; ns++)
    { if (ns->out)
      { if (soap->encodingStyle == ns->out)
          soap->encodingStyle = SOAP_STR_EOS;
        SOAP_FREE(soap, ns->out);
        ns->out = NULL;
      }
      if (soap->encodingStyle == ns->ns)
        soap->encodingStyle = SOAP_STR_EOS;
    }
    SOAP_FREE(soap, soap->local_namespaces);
    soap->local_namespaces = NULL;
  }
#ifndef WITH_LEANER
  while (soap->xlist)
  { struct soap_xlist *xp = soap->xlist->next;
    SOAP_FREE(soap, soap->xlist);
    soap->xlist = xp;
  }
#endif
#ifndef WITH_NOIDREF
  soap_free_pht(soap);
  soap_free_iht(soap);
#endif
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
callq 0x16663
cmpq $0x0, 0x90(%rbx)
je 0x1404c
movq %rbx, %rdi
xorl %esi, %esi
callq 0x12694
jmp 0x14036
movq 0x1e5e0(%rbx), %r14
testq %r14, %r14
je 0x14071
movq (%r14), %r15
movq 0x10(%r14), %rdi
callq 0x3030
movq %r14, %rdi
callq 0x3030
movq %r15, %r14
jmp 0x14053
andq $0x0, 0x1e5e0(%rbx)
movq 0xc180(%rbx), %rdi
callq 0x3030
andq $0x0, 0xc190(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0xc180(%rbx)
movq 0x80(%rbx), %r14
testq %r14, %r14
je 0x140fb
addq $0x18, %r14
leaq 0xef13(%rip), %r15      # 0x22fc1
cmpq $0x0, -0x18(%r14)
je 0x140e7
movq (%r14), %rdi
movq 0x38(%rbx), %rax
testq %rdi, %rdi
je 0x140d7
cmpq %rdi, %rax
jne 0x140ca
movq %r15, 0x38(%rbx)
callq 0x3030
andq $0x0, (%r14)
movq 0x38(%rbx), %rax
cmpq -0x10(%r14), %rax
jne 0x140e1
movq %r15, 0x38(%rbx)
addq $0x20, %r14
jmp 0x140ae
movq 0x80(%rbx), %rdi
callq 0x3030
andq $0x0, 0x80(%rbx)
movq 0x1f310(%rbx), %rdi
testq %rdi, %rdi
je 0x1411b
movq (%rdi), %r14
callq 0x3030
movq %r14, 0x1f310(%rbx)
movq %r14, %rdi
jmp 0x14102
movq 0xbf20(%rbx), %rdi
testq %rdi, %rdi
je 0x14134
movq (%rdi), %r14
callq 0x3030
movq %r14, %rdi
jmp 0x14122
andq $0x0, 0xbf20(%rbx)
andw $0x0, 0xbf28(%rbx)
movl $0x7e4, %eax            # imm = 0x7E4
cmpq $0x17e4, %rax           # imm = 0x17E4
je 0x1415b
andq $0x0, (%rbx,%rax,8)
incq %rax
jmp 0x14149
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x182aa
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: fplugin
static void *
fplugin(struct soap *soap, const char *id)
{ register struct soap_plugin *p;
  for (p = soap->plugins; p; p = p->next)
    if (p->id == id || !strcmp(p->id, id))
      return p->data;
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r15
movq %rdi, %r14
addq $0xbf70, %r14           # imm = 0xBF70
xorl %ebx, %ebx
movq (%r14), %r14
testq %r14, %r14
je 0x1419d
movq 0x8(%r14), %rdi
cmpq %r15, %rdi
je 0x14199
movq %r15, %rsi
callq 0x31f0
testl %eax, %eax
jne 0x1417c
movq 0x10(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_decode
static const char*
soap_decode(char *buf, size_t len, const char *val, const char *sep)
{ const char *s;
  char *t = buf;
  for (s = val; *s; s++)
    if (*s != ' ' && *s != '\t' && !strchr(sep, *s))
      break;
  if (*s == '"')
  { s++;
    while (*s && *s != '"' && --len)
      *t++ = *s++;
  }
  else
  { while (*s && !soap_blank((soap_wchar)*s) && !strchr(sep, *s) && --len)
    { if (*s == '%')
      { *t++ = ((s[1] >= 'A' ? (s[1] & 0x7) + 9 : s[1] - '0') << 4)
              + (s[2] >= 'A' ? (s[2] & 0x7) + 9 : s[2] - '0');
        s += 3;
      }
      else
        *t++ = *s++;
    }
  }
  *t = '\0';
  while (*s && !strchr(sep, *s))
    s++;
  return s;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r14
movq %rdx, %rbx
movq %rsi, %r12
movq %rdi, %r15
movzbl (%rbx), %ebp
cmpl $0x9, %ebp
je 0x15da8
cmpl $0x20, %ebp
je 0x15da8
testl %ebp, %ebp
je 0x15dda
movsbl %bpl, %esi
movq %r14, %rdi
callq 0x3130
testq %rax, %rax
je 0x15dad
incq %rbx
jmp 0x15d86
cmpb $0x22, %bpl
jne 0x15dda
incq %rbx
decq %r12
movzbl (%rbx), %eax
testl %eax, %eax
je 0x15e48
cmpl $0x22, %eax
je 0x15e48
subq $0x1, %r12
jb 0x15e48
movb %al, (%r15)
incq %r15
incq %rbx
jmp 0x15db9
decq %r12
cmpb $0x21, %bpl
jb 0x15e48
movsbl %bpl, %esi
movq %r14, %rdi
callq 0x3130
testq %rax, %rax
jne 0x15e48
subq $0x1, %r12
jb 0x15e48
cmpb $0x25, %bpl
jne 0x15e3a
movzbl 0x1(%rbx), %eax
movl %eax, %ecx
andb $0x7, %cl
addb $0x9, %cl
cmpb $0x41, %al
movzbl %cl, %ecx
cmovll %eax, %ecx
shlb $0x4, %cl
movb 0x2(%rbx), %al
movl %eax, %edx
andb $0x7, %dl
addb $0x9, %dl
leal -0x30(%rax), %esi
cmpb $0x41, %al
movzbl %sil, %eax
movzbl %dl, %ebp
cmovll %eax, %ebp
addb %cl, %bpl
addq $0x3, %rbx
jmp 0x15e3d
incq %rbx
movb %bpl, (%r15)
incq %r15
movb (%rbx), %bpl
jmp 0x15ddd
movb $0x0, (%r15)
movsbl (%rbx), %esi
testl %esi, %esi
je 0x15e65
movq %r14, %rdi
callq 0x3130
testq %rax, %rax
jne 0x15e65
incq %rbx
jmp 0x15e4c
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_hash
SOAP_FMAC2
soap_hash(register const char *s)
{ register size_t h = 0;
  while (*s)
    h = 65599*h + *s++;
  return h % SOAP_IDHASH;
}

// Assembly:
xorl %eax, %eax
movsbq (%rdi), %rcx
testq %rcx, %rcx
je 0x16229
imulq $0x1003f, %rax, %rax    # imm = 0x1003F
incq %rdi
addq %rcx, %rax
jmp 0x16211
movl $0x7cf, %ecx            # imm = 0x7CF
xorl %edx, %edx
divq %rcx
movq %rdx, %rax
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_is_single
SOAP_FMAC2
soap_is_single(struct soap *soap, struct soap_plist *pp)
{ if (soap->part == SOAP_IN_HEADER)
    return 1;
  if (!pp)
    return 0;
  if (soap->mode & SOAP_IO_LENGTH)
    return pp->mark1 == 0;
  return pp->mark2 == 0;
}

// Assembly:
movb $0x1, %al
cmpw $0x3, 0x1e5f0(%rdi)
je 0x1646c
testq %rsi, %rsi
je 0x16461
testb $0x8, 0x4(%rdi)
jne 0x16465
cmpb $0x0, 0x21(%rsi)
jmp 0x16469
xorl %eax, %eax
jmp 0x1646c
cmpb $0x0, 0x20(%rsi)
sete %al
movzbl %al, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_set_embedded
SOAP_FMAC2
soap_set_embedded(struct soap *soap, struct soap_plist *pp)
{ if (!pp)
    return;
  if (soap->mode & SOAP_IO_LENGTH)
    pp->mark1 = 1;
  else
    pp->mark2 = 1;
}

// Assembly:
testq %rsi, %rsi
je 0x1647f
testb $0x8, 0x4(%rdi)
jne 0x16480
movb $0x1, 0x21(%rsi)
retq
movb $0x1, 0x20(%rsi)
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_free_ns
static void
soap_free_ns(struct soap *soap)
{ register struct soap_nlist *np, *nq;
  DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Free namespace stack\n"));
  for (np = soap->nlist; np; np = nq)
  { nq = np->next;
    SOAP_FREE(soap, np);
  }
  soap->nlist = NULL;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x88(%rdi), %rdi
testq %rdi, %rdi
je 0x16683
movq (%rdi), %r14
callq 0x3030
movq %r14, %rdi
jmp 0x16671
andq $0x0, 0x88(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/hkshenSmart[P]ONVIF-discovery_cs/stdsoap2.c
// Function: soap_clr_attr
SOAP_FMAC2
soap_clr_attr(struct soap *soap)
{ register struct soap_attribute *tp;
#ifndef WITH_LEAN
  if ((soap->mode & SOAP_XML_CANONICAL))
  { while (soap->attributes)
    { tp = soap->attributes->next;
      if (soap->attributes->value)
        SOAP_FREE(soap, soap->attributes->value);
      SOAP_FREE(soap, soap->attributes);
      soap->attributes = tp;
    }
  }
  else
#endif
  { for (tp = soap->attributes; tp; tp = tp->next)
      tp->visible = 0;
  }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x1e5e0(%rdi), %rbx
testb $0x1, 0x6(%rdi)
jne 0x167e7
movq (%rbx), %rbx
testq %rbx, %rbx
je 0x1680b
andw $0x0, 0x28(%rbx)
jmp 0x167d8
movq (%rbx), %rax
testq %rax, %rax
je 0x1680b
movq (%rax), %r14
movq 0x10(%rax), %rdi
callq 0x3030
movq (%rbx), %rdi
callq 0x3030
movq %r14, (%rbx)
movq %r14, %rax
jmp 0x167ea
addq $0x8, %rsp
popq %rbx
popq %r14
retq