
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Unknown calling convention */

void delete_all_jobs(int running_only)

{
  int iVar1;
  int iVar2;
  int job_index;
  int iVar3;
  int in_GS_OFFSET;
  sigset_t set;
  sigset_t oset;
  
  iVar1 = *(int *)(in_GS_OFFSET + 0x14);
  sigemptyset((sigset_t *)&set);
  sigaddset((sigset_t *)&set,0x11);
  sigemptyset((sigset_t *)&oset);
  sigprocmask(0,(sigset_t *)&set,(sigset_t *)&oset);
  if (js.j_jobslots == 0) {
    if (running_only != 0) goto LAB_0006fd20;
  }
  else {
    js.j_previous = -1;
    js.j_current = -1;
    if (js.j_jobslots < 1) {
      if (running_only != 0) goto LAB_0006fd20;
    }
    else {
      iVar2 = js.j_jobslots;
      if (running_only != 0) {
        job_index = 0;
        do {
          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||
                 (jobs_list_frozen != 0))) {
            job_index = job_index + 1;
            if (iVar2 <= job_index) goto LAB_0006fd20;
          }
          iVar3 = job_index + 1;
          delete_job(job_index,3);
          iVar2 = js.j_jobslots;
          job_index = iVar3;
        } while (iVar3 < js.j_jobslots);
        goto LAB_0006fd20;
      }
      do {
        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {
          delete_job(running_only,3);
          iVar2 = js.j_jobslots;
        }
        running_only = running_only + 1;
      } while (running_only < iVar2);
    }
    free(jobs);
    js.j_jobslots = 0;
    js.j_njobs = 0;
    js.j_lastj = 0;
    js.j_firstj = 0;
  }
  if ((bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0)) {
    free(bgpids.storage);
    bgpids.storage = (pidstat *)0x0;
    bgpids.nalloc = 0;
    bgpids.head = 0;
    bgpids.npid = 0;
  }
LAB_0006fd20:
  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);
  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    __stack_chk_fail_local();
  }
  return;
}



/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

void delete_all_jobs(int param_1)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int in_GS_OFFSET;
  sigset_t local_120;
  sigset_t local_a0;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x6fc59;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  sigemptyset(&local_120);
  sigaddset(&local_120,0x11);
  sigemptyset(&local_a0);
  sigprocmask(0,&local_120,&local_a0);
  if (DAT_001727d8 == 0) {
    if (param_1 != 0) goto LAB_0006fd20;
  }
  else {
    DAT_001727f0 = 0xffffffff;
    DAT_001727ec = 0xffffffff;
    if (DAT_001727d8 < 1) {
      if (param_1 != 0) goto LAB_0006fd20;
    }
    else {
      iVar2 = DAT_001727d8;
      if (param_1 != 0) {
        iVar3 = 0;
        do {
          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||
                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {
            iVar3 = iVar3 + 1;
            if (iVar2 <= iVar3) goto LAB_0006fd20;
          }
          iVar3 = iVar3 + 1;
          FUN_00068fb0();
          iVar2 = DAT_001727d8;
        } while (iVar3 < DAT_001727d8);
        goto LAB_0006fd20;
      }
      do {
        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {
          FUN_00068fb0();
          iVar2 = DAT_001727d8;
        }
        param_1 = param_1 + 1;
      } while (param_1 < iVar2);
    }
    free(jobs);
    DAT_001727d8 = 0;
    DAT_001727e4 = 0;
    DAT_001727dc = 0;
    DAT_001727e0 = 0;
  }
  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {
    free(bgpids);
    bgpids = (void *)0x0;
    DAT_00177f00 = 0;
    DAT_00177efc = 0;
    DAT_00177f04 = 0;
  }
LAB_0006fd20:
  sigprocmask(2,&local_a0,(sigset_t *)0x0);
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_0010f8b0();
  }
  return;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x000312b0
ADD EBX,0x1023a7
SUB ESP,0x128
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0x118],EAX
XOR EAX,EAX
LEA EBP,[ESP + 0x18]
MOV ESI,dword ptr [ESP + 0x13c]
PUSH EBP
CALL 0x0002ea40
POP ECX
POP EDI
PUSH 0x11
PUSH EBP
CALL 0x0002e810
POP EAX
LEA EDI,[ESP + 0x98]
PUSH EDI
CALL 0x0002ea40
ADD ESP,0xc
PUSH EDI
PUSH EBP
PUSH 0x0
CALL 0x0002e1a0
MOV EAX,dword ptr [EBX + 0x7d8]
ADD ESP,0x10
TEST EAX,EAX
JZ 0x0006fd50
MOV dword ptr [EBX + 0x7f0],0xffffffff
MOV dword ptr [EBX + 0x7ec],0xffffffff
JLE 0x0006fe10
TEST ESI,ESI
JZ 0x0006fda0
XOR ESI,ESI
JMP 0x0006fce7
ADD ESI,0x1
CMP ESI,EAX
JGE 0x0006fd20
MOV EDX,dword ptr [EBX + 0x5ef4]
MOV EDX,dword ptr [EDX + ESI*0x4]
TEST EDX,EDX
JZ 0x0006fce0
CMP dword ptr [EDX + 0xc],0x1
JNZ 0x0006fce0
MOV EDX,dword ptr [EBX + 0x7020]
TEST EDX,EDX
JNZ 0x0006fce0
MOV EAX,ESI
MOV EDX,0x3
ADD ESI,0x1
CALL 0x00068fb0
MOV EAX,dword ptr [EBX + 0x7d8]
CMP ESI,EAX
JL 0x0006fce7
LEA ESI,[ESI]
SUB ESP,0x4
PUSH 0x0
PUSH EDI
PUSH 0x2
CALL 0x0002e1a0
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0x10c]
XOR EAX,dword ptr GS:[0x14]
JNZ 0x0006fe1a
ADD ESP,0x11c
POP EBX
POP ESI
POP EDI
POP EBP
RET
TEST ESI,ESI
JNZ 0x0006fd20
MOV EAX,dword ptr [EBX + 0x5ef8]
TEST EAX,EAX
JZ 0x0006fd20
MOV EDX,dword ptr [EBX + 0x5f00]
TEST EDX,EDX
JZ 0x0006fd20
SUB ESP,0xc
PUSH EAX
CALL 0x0002e200
ADD ESP,0x10
MOV dword ptr [EBX + 0x5ef8],0x0
MOV dword ptr [EBX + 0x5f00],0x0
MOV dword ptr [EBX + 0x5efc],0x0
MOV dword ptr [EBX + 0x5f04],0x0
JMP 0x0006fd20
MOV EDX,dword ptr [EBX + 0x5ef4]
MOV EBP,dword ptr [EDX + ESI*0x4]
TEST EBP,EBP
JZ 0x0006fdc9
MOV ECX,dword ptr [EBX + 0x7020]
TEST ECX,ECX
JNZ 0x0006fdc9
MOV EAX,ESI
MOV EDX,0x3
CALL 0x00068fb0
MOV EAX,dword ptr [EBX + 0x7d8]
ADD ESI,0x1
CMP ESI,EAX
JL 0x0006fda0
SUB ESP,0xc
PUSH dword ptr [EBX + 0x5ef4]
CALL 0x0002e200
ADD ESP,0x10
MOV dword ptr [EBX + 0x7d8],0x0
MOV dword ptr [EBX + 0x7e4],0x0
MOV dword ptr [EBX + 0x7dc],0x0
MOV dword ptr [EBX + 0x7e0],0x0
JMP 0x0006fd54
TEST ESI,ESI
JNZ 0x0006fd20
JMP 0x0006fdd0
CALL 0x0010f8b0
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid delete_all_jobs(int param_1)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0010f8b0();\n  }\n  return;\n}\n\n" comment (function_definition "void delete_all_jobs(int param_1)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0010f8b0();\n  }\n  return;\n}" primitive_type (function_declarator "delete_all_jobs(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0010f8b0();\n  }\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "sigset_t local_120;" type_identifier identifier ;) (declaration "sigset_t local_a0;" type_identifier identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x6fc59;" (assignment_expression "uStack_14 = 0x6fc59" identifier = number_literal) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "sigemptyset(&local_120);" (call_expression "sigemptyset(&local_120)" identifier (argument_list "(&local_120)" ( (pointer_expression "&local_120" & identifier) ))) ;) (expression_statement "sigaddset(&local_120,0x11);" (call_expression "sigaddset(&local_120,0x11)" identifier (argument_list "(&local_120,0x11)" ( (pointer_expression "&local_120" & identifier) , number_literal ))) ;) (expression_statement "sigemptyset(&local_a0);" (call_expression "sigemptyset(&local_a0)" identifier (argument_list "(&local_a0)" ( (pointer_expression "&local_a0" & identifier) ))) ;) (expression_statement "sigprocmask(0,&local_120,&local_a0);" (call_expression "sigprocmask(0,&local_120,&local_a0)" identifier (argument_list "(0,&local_120,&local_a0)" ( number_literal , (pointer_expression "&local_120" & identifier) , (pointer_expression "&local_a0" & identifier) ))) ;) (if_statement "if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" if (parenthesized_expression "(DAT_001727d8 == 0)" ( (binary_expression "DAT_001727d8 == 0" identifier == number_literal) )) (compound_statement "{\n    if (param_1 != 0) goto LAB_0006fd20;\n  }" { (if_statement "if (param_1 != 0) goto LAB_0006fd20;" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) }) (else_clause "else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" else (compound_statement "{\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" { (expression_statement "DAT_001727f0 = 0xffffffff;" (assignment_expression "DAT_001727f0 = 0xffffffff" identifier = number_literal) ;) (expression_statement "DAT_001727ec = 0xffffffff;" (assignment_expression "DAT_001727ec = 0xffffffff" identifier = number_literal) ;) (if_statement "if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" if (parenthesized_expression "(DAT_001727d8 < 1)" ( (binary_expression "DAT_001727d8 < 1" identifier < number_literal) )) (compound_statement "{\n      if (param_1 != 0) goto LAB_0006fd20;\n    }" { (if_statement "if (param_1 != 0) goto LAB_0006fd20;" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) }) (else_clause "else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" else (compound_statement "{\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" { (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) (if_statement "if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (compound_statement "{\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (do_statement "do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);" do (compound_statement "{\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" { (while_statement "while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }" while (parenthesized_expression "(((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0)))" ( (parenthesized_expression "((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))" ( (binary_expression "(iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0)" (parenthesized_expression "(iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1))" ( (comma_expression "iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)" (assignment_expression "iVar1 = *(int *)((int)jobs + iVar3 * 4)" identifier = (pointer_expression "*(int *)((int)jobs + iVar3 * 4)" * (cast_expression "(int *)((int)jobs + iVar3 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)jobs + iVar3 * 4)" ( (binary_expression "(int)jobs + iVar3 * 4" (cast_expression "(int)jobs" ( (type_descriptor "int" primitive_type) ) identifier) + (binary_expression "iVar3 * 4" identifier * number_literal)) ))))) , (binary_expression "iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)" (binary_expression "iVar1 == 0" identifier == number_literal) || (parenthesized_expression "(*(int *)(iVar1 + 0xc) != 1)" ( (binary_expression "*(int *)(iVar1 + 0xc) != 1" (pointer_expression "*(int *)(iVar1 + 0xc)" * (cast_expression "(int *)(iVar1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0xc)" ( (binary_expression "iVar1 + 0xc" identifier + number_literal) )))) != number_literal) )))) )) || (parenthesized_expression "(DAT_00179020 != 0)" ( (binary_expression "DAT_00179020 != 0" identifier != number_literal) ))) )) )) (compound_statement "{\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }" { (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (if_statement "if (iVar2 <= iVar3) goto LAB_0006fd20;" if (parenthesized_expression "(iVar2 <= iVar3)" ( (binary_expression "iVar2 <= iVar3" identifier <= identifier) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) })) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (expression_statement "FUN_00068fb0();" (call_expression "FUN_00068fb0()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) }) while (parenthesized_expression "(iVar3 < DAT_001727d8)" ( (binary_expression "iVar3 < DAT_001727d8" identifier < identifier) )) ;) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;) })) (do_statement "do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);" do (compound_statement "{\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      }" { (if_statement "if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" if (parenthesized_expression "((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0))" ( (binary_expression "(*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)" (parenthesized_expression "(*(int *)((int)jobs + param_1 * 4) != 0)" ( (binary_expression "*(int *)((int)jobs + param_1 * 4) != 0" (pointer_expression "*(int *)((int)jobs + param_1 * 4)" * (cast_expression "(int *)((int)jobs + param_1 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)jobs + param_1 * 4)" ( (binary_expression "(int)jobs + param_1 * 4" (cast_expression "(int)jobs" ( (type_descriptor "int" primitive_type) ) identifier) + (binary_expression "param_1 * 4" identifier * number_literal)) )))) != number_literal) )) && (parenthesized_expression "(DAT_00179020 == 0)" ( (binary_expression "DAT_00179020 == 0" identifier == number_literal) ))) )) (compound_statement "{\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" { (expression_statement "FUN_00068fb0();" (call_expression "FUN_00068fb0()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) })) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_1 < iVar2)" ( (binary_expression "param_1 < iVar2" identifier < identifier) )) ;) }))) (expression_statement "free(jobs);" (call_expression "free(jobs)" identifier (argument_list "(jobs)" ( identifier ))) ;) (expression_statement "DAT_001727d8 = 0;" (assignment_expression "DAT_001727d8 = 0" identifier = number_literal) ;) (expression_statement "DAT_001727e4 = 0;" (assignment_expression "DAT_001727e4 = 0" identifier = number_literal) ;) (expression_statement "DAT_001727dc = 0;" (assignment_expression "DAT_001727dc = 0" identifier = number_literal) ;) (expression_statement "DAT_001727e0 = 0;" (assignment_expression "DAT_001727e0 = 0" identifier = number_literal) ;) }))) (if_statement "if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }" if (parenthesized_expression "((bgpids != (void *)0x0) && (DAT_00177f00 != 0))" ( (binary_expression "(bgpids != (void *)0x0) && (DAT_00177f00 != 0)" (parenthesized_expression "(bgpids != (void *)0x0)" ( (binary_expression "bgpids != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(DAT_00177f00 != 0)" ( (binary_expression "DAT_00177f00 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }" { (expression_statement "free(bgpids);" (call_expression "free(bgpids)" identifier (argument_list "(bgpids)" ( identifier ))) ;) (expression_statement "bgpids = (void *)0x0;" (assignment_expression "bgpids = (void *)0x0" identifier = (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "DAT_00177f00 = 0;" (assignment_expression "DAT_00177f00 = 0" identifier = number_literal) ;) (expression_statement "DAT_00177efc = 0;" (assignment_expression "DAT_00177efc = 0" identifier = number_literal) ;) (expression_statement "DAT_00177f04 = 0;" (assignment_expression "DAT_00177f04 = 0" identifier = number_literal) ;) })) (labeled_statement "LAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);" statement_identifier : (expression_statement "sigprocmask(2,&local_a0,(sigset_t *)0x0);" (call_expression "sigprocmask(2,&local_a0,(sigset_t *)0x0)" identifier (argument_list "(2,&local_a0,(sigset_t *)0x0)" ( number_literal , (pointer_expression "&local_a0" & identifier) , (cast_expression "(sigset_t *)0x0" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ))) ;)) (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0010f8b0();\n  }" if (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    FUN_0010f8b0();\n  }" { comment (expression_statement "FUN_0010f8b0();" (call_expression "FUN_0010f8b0()" identifier (argument_list "()" ( ))) ;) })) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nvoid delete_all_jobs(int running_only)\n\n{\n  int iVar1;\n  int iVar2;\n  int job_index;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t set;\n  sigset_t oset;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset((sigset_t *)&set);\n  sigaddset((sigset_t *)&set,0x11);\n  sigemptyset((sigset_t *)&oset);\n  sigprocmask(0,(sigset_t *)&set,(sigset_t *)&oset);\n  if (js.j_jobslots == 0) {\n    if (running_only != 0) goto LAB_0006fd20;\n  }\n  else {\n    js.j_previous = -1;\n    js.j_current = -1;\n    if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }\n    free(jobs);\n    js.j_jobslots = 0;\n    js.j_njobs = 0;\n    js.j_lastj = 0;\n    js.j_firstj = 0;\n  }\n  if ((bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0)) {\n    free(bgpids.storage);\n    bgpids.storage = (pidstat *)0x0;\n    bgpids.nalloc = 0;\n    bgpids.head = 0;\n    bgpids.npid = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return;\n}\n\n" comment comment (function_definition "void delete_all_jobs(int running_only)\n\n{\n  int iVar1;\n  int iVar2;\n  int job_index;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t set;\n  sigset_t oset;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset((sigset_t *)&set);\n  sigaddset((sigset_t *)&set,0x11);\n  sigemptyset((sigset_t *)&oset);\n  sigprocmask(0,(sigset_t *)&set,(sigset_t *)&oset);\n  if (js.j_jobslots == 0) {\n    if (running_only != 0) goto LAB_0006fd20;\n  }\n  else {\n    js.j_previous = -1;\n    js.j_current = -1;\n    if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }\n    free(jobs);\n    js.j_jobslots = 0;\n    js.j_njobs = 0;\n    js.j_lastj = 0;\n    js.j_firstj = 0;\n  }\n  if ((bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0)) {\n    free(bgpids.storage);\n    bgpids.storage = (pidstat *)0x0;\n    bgpids.nalloc = 0;\n    bgpids.head = 0;\n    bgpids.npid = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return;\n}" primitive_type (function_declarator "delete_all_jobs(int running_only)" identifier (parameter_list "(int running_only)" ( (parameter_declaration "int running_only" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int job_index;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t set;\n  sigset_t oset;\n  \n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset((sigset_t *)&set);\n  sigaddset((sigset_t *)&set,0x11);\n  sigemptyset((sigset_t *)&oset);\n  sigprocmask(0,(sigset_t *)&set,(sigset_t *)&oset);\n  if (js.j_jobslots == 0) {\n    if (running_only != 0) goto LAB_0006fd20;\n  }\n  else {\n    js.j_previous = -1;\n    js.j_current = -1;\n    if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }\n    free(jobs);\n    js.j_jobslots = 0;\n    js.j_njobs = 0;\n    js.j_lastj = 0;\n    js.j_firstj = 0;\n  }\n  if ((bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0)) {\n    free(bgpids.storage);\n    bgpids.storage = (pidstat *)0x0;\n    bgpids.nalloc = 0;\n    bgpids.head = 0;\n    bgpids.npid = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int job_index;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "sigset_t set;" type_identifier identifier ;) (declaration "sigset_t oset;" type_identifier identifier ;) (expression_statement "iVar1 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "iVar1 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "sigemptyset((sigset_t *)&set);" (call_expression "sigemptyset((sigset_t *)&set)" identifier (argument_list "((sigset_t *)&set)" ( (cast_expression "(sigset_t *)&set" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&set" & identifier)) ))) ;) (expression_statement "sigaddset((sigset_t *)&set,0x11);" (call_expression "sigaddset((sigset_t *)&set,0x11)" identifier (argument_list "((sigset_t *)&set,0x11)" ( (cast_expression "(sigset_t *)&set" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&set" & identifier)) , number_literal ))) ;) (expression_statement "sigemptyset((sigset_t *)&oset);" (call_expression "sigemptyset((sigset_t *)&oset)" identifier (argument_list "((sigset_t *)&oset)" ( (cast_expression "(sigset_t *)&oset" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&oset" & identifier)) ))) ;) (expression_statement "sigprocmask(0,(sigset_t *)&set,(sigset_t *)&oset);" (call_expression "sigprocmask(0,(sigset_t *)&set,(sigset_t *)&oset)" identifier (argument_list "(0,(sigset_t *)&set,(sigset_t *)&oset)" ( number_literal , (cast_expression "(sigset_t *)&set" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&set" & identifier)) , (cast_expression "(sigset_t *)&oset" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&oset" & identifier)) ))) ;) (if_statement "if (js.j_jobslots == 0) {\n    if (running_only != 0) goto LAB_0006fd20;\n  }\n  else {\n    js.j_previous = -1;\n    js.j_current = -1;\n    if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }\n    free(jobs);\n    js.j_jobslots = 0;\n    js.j_njobs = 0;\n    js.j_lastj = 0;\n    js.j_firstj = 0;\n  }" if (parenthesized_expression "(js.j_jobslots == 0)" ( (binary_expression "js.j_jobslots == 0" (field_expression "js.j_jobslots" identifier . field_identifier) == number_literal) )) (compound_statement "{\n    if (running_only != 0) goto LAB_0006fd20;\n  }" { (if_statement "if (running_only != 0) goto LAB_0006fd20;" if (parenthesized_expression "(running_only != 0)" ( (binary_expression "running_only != 0" identifier != number_literal) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) }) (else_clause "else {\n    js.j_previous = -1;\n    js.j_current = -1;\n    if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }\n    free(jobs);\n    js.j_jobslots = 0;\n    js.j_njobs = 0;\n    js.j_lastj = 0;\n    js.j_firstj = 0;\n  }" else (compound_statement "{\n    js.j_previous = -1;\n    js.j_current = -1;\n    if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }\n    free(jobs);\n    js.j_jobslots = 0;\n    js.j_njobs = 0;\n    js.j_lastj = 0;\n    js.j_firstj = 0;\n  }" { (expression_statement "js.j_previous = -1;" (assignment_expression "js.j_previous = -1" (field_expression "js.j_previous" identifier . field_identifier) = number_literal) ;) (expression_statement "js.j_current = -1;" (assignment_expression "js.j_current = -1" (field_expression "js.j_current" identifier . field_identifier) = number_literal) ;) (if_statement "if (js.j_jobslots < 1) {\n      if (running_only != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }" if (parenthesized_expression "(js.j_jobslots < 1)" ( (binary_expression "js.j_jobslots < 1" (field_expression "js.j_jobslots" identifier . field_identifier) < number_literal) )) (compound_statement "{\n      if (running_only != 0) goto LAB_0006fd20;\n    }" { (if_statement "if (running_only != 0) goto LAB_0006fd20;" if (parenthesized_expression "(running_only != 0)" ( (binary_expression "running_only != 0" identifier != number_literal) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) }) (else_clause "else {\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }" else (compound_statement "{\n      iVar2 = js.j_jobslots;\n      if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);\n    }" { (expression_statement "iVar2 = js.j_jobslots;" (assignment_expression "iVar2 = js.j_jobslots" identifier = (field_expression "js.j_jobslots" identifier . field_identifier)) ;) (if_statement "if (running_only != 0) {\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }" if (parenthesized_expression "(running_only != 0)" ( (binary_expression "running_only != 0" identifier != number_literal) )) (compound_statement "{\n        job_index = 0;\n        do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);\n        goto LAB_0006fd20;\n      }" { (expression_statement "job_index = 0;" (assignment_expression "job_index = 0" identifier = number_literal) ;) (do_statement "do {\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        } while (iVar3 < js.j_jobslots);" do (compound_statement "{\n          while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }\n          iVar3 = job_index + 1;\n          delete_job(job_index,3);\n          iVar2 = js.j_jobslots;\n          job_index = iVar3;\n        }" { (while_statement "while (((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))) {\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }" while (parenthesized_expression "(((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0)))" ( (parenthesized_expression "((jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0))" ( (binary_expression "(jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)) ||\n                 (jobs_list_frozen != 0)" (parenthesized_expression "(jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING))" ( (binary_expression "jobs[job_index] == (JOB *)0x0 || (jobs[job_index]->state != JRUNNING)" (binary_expression "jobs[job_index] == (JOB *)0x0" (subscript_expression "jobs[job_index]" identifier [ identifier ]) == (cast_expression "(JOB *)0x0" ( (type_descriptor "JOB *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) || (parenthesized_expression "(jobs[job_index]->state != JRUNNING)" ( (binary_expression "jobs[job_index]->state != JRUNNING" (field_expression "jobs[job_index]->state" (subscript_expression "jobs[job_index]" identifier [ identifier ]) -> field_identifier) != identifier) ))) )) || (parenthesized_expression "(jobs_list_frozen != 0)" ( (binary_expression "jobs_list_frozen != 0" identifier != number_literal) ))) )) )) (compound_statement "{\n            job_index = job_index + 1;\n            if (iVar2 <= job_index) goto LAB_0006fd20;\n          }" { (expression_statement "job_index = job_index + 1;" (assignment_expression "job_index = job_index + 1" identifier = (binary_expression "job_index + 1" identifier + number_literal)) ;) (if_statement "if (iVar2 <= job_index) goto LAB_0006fd20;" if (parenthesized_expression "(iVar2 <= job_index)" ( (binary_expression "iVar2 <= job_index" identifier <= identifier) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) })) (expression_statement "iVar3 = job_index + 1;" (assignment_expression "iVar3 = job_index + 1" identifier = (binary_expression "job_index + 1" identifier + number_literal)) ;) (expression_statement "delete_job(job_index,3);" (call_expression "delete_job(job_index,3)" identifier (argument_list "(job_index,3)" ( identifier , number_literal ))) ;) (expression_statement "iVar2 = js.j_jobslots;" (assignment_expression "iVar2 = js.j_jobslots" identifier = (field_expression "js.j_jobslots" identifier . field_identifier)) ;) (expression_statement "job_index = iVar3;" (assignment_expression "job_index = iVar3" identifier = identifier) ;) }) while (parenthesized_expression "(iVar3 < js.j_jobslots)" ( (binary_expression "iVar3 < js.j_jobslots" identifier < (field_expression "js.j_jobslots" identifier . field_identifier)) )) ;) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;) })) (do_statement "do {\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      } while (running_only < iVar2);" do (compound_statement "{\n        if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }\n        running_only = running_only + 1;\n      }" { (if_statement "if ((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)) {\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }" if (parenthesized_expression "((jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0))" ( (binary_expression "(jobs[running_only] != (JOB *)0x0) && (jobs_list_frozen == 0)" (parenthesized_expression "(jobs[running_only] != (JOB *)0x0)" ( (binary_expression "jobs[running_only] != (JOB *)0x0" (subscript_expression "jobs[running_only]" identifier [ identifier ]) != (cast_expression "(JOB *)0x0" ( (type_descriptor "JOB *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(jobs_list_frozen == 0)" ( (binary_expression "jobs_list_frozen == 0" identifier == number_literal) ))) )) (compound_statement "{\n          delete_job(running_only,3);\n          iVar2 = js.j_jobslots;\n        }" { (expression_statement "delete_job(running_only,3);" (call_expression "delete_job(running_only,3)" identifier (argument_list "(running_only,3)" ( identifier , number_literal ))) ;) (expression_statement "iVar2 = js.j_jobslots;" (assignment_expression "iVar2 = js.j_jobslots" identifier = (field_expression "js.j_jobslots" identifier . field_identifier)) ;) })) (expression_statement "running_only = running_only + 1;" (assignment_expression "running_only = running_only + 1" identifier = (binary_expression "running_only + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(running_only < iVar2)" ( (binary_expression "running_only < iVar2" identifier < identifier) )) ;) }))) (expression_statement "free(jobs);" (call_expression "free(jobs)" identifier (argument_list "(jobs)" ( identifier ))) ;) (expression_statement "js.j_jobslots = 0;" (assignment_expression "js.j_jobslots = 0" (field_expression "js.j_jobslots" identifier . field_identifier) = number_literal) ;) (expression_statement "js.j_njobs = 0;" (assignment_expression "js.j_njobs = 0" (field_expression "js.j_njobs" identifier . field_identifier) = number_literal) ;) (expression_statement "js.j_lastj = 0;" (assignment_expression "js.j_lastj = 0" (field_expression "js.j_lastj" identifier . field_identifier) = number_literal) ;) (expression_statement "js.j_firstj = 0;" (assignment_expression "js.j_firstj = 0" (field_expression "js.j_firstj" identifier . field_identifier) = number_literal) ;) }))) (if_statement "if ((bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0)) {\n    free(bgpids.storage);\n    bgpids.storage = (pidstat *)0x0;\n    bgpids.nalloc = 0;\n    bgpids.head = 0;\n    bgpids.npid = 0;\n  }" if (parenthesized_expression "((bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0))" ( (binary_expression "(bgpids.storage != (pidstat *)0x0) && (bgpids.nalloc != 0)" (parenthesized_expression "(bgpids.storage != (pidstat *)0x0)" ( (binary_expression "bgpids.storage != (pidstat *)0x0" (field_expression "bgpids.storage" identifier . field_identifier) != (cast_expression "(pidstat *)0x0" ( (type_descriptor "pidstat *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(bgpids.nalloc != 0)" ( (binary_expression "bgpids.nalloc != 0" (field_expression "bgpids.nalloc" identifier . field_identifier) != number_literal) ))) )) (compound_statement "{\n    free(bgpids.storage);\n    bgpids.storage = (pidstat *)0x0;\n    bgpids.nalloc = 0;\n    bgpids.head = 0;\n    bgpids.npid = 0;\n  }" { (expression_statement "free(bgpids.storage);" (call_expression "free(bgpids.storage)" identifier (argument_list "(bgpids.storage)" ( (field_expression "bgpids.storage" identifier . field_identifier) ))) ;) (expression_statement "bgpids.storage = (pidstat *)0x0;" (assignment_expression "bgpids.storage = (pidstat *)0x0" (field_expression "bgpids.storage" identifier . field_identifier) = (cast_expression "(pidstat *)0x0" ( (type_descriptor "pidstat *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "bgpids.nalloc = 0;" (assignment_expression "bgpids.nalloc = 0" (field_expression "bgpids.nalloc" identifier . field_identifier) = number_literal) ;) (expression_statement "bgpids.head = 0;" (assignment_expression "bgpids.head = 0" (field_expression "bgpids.head" identifier . field_identifier) = number_literal) ;) (expression_statement "bgpids.npid = 0;" (assignment_expression "bgpids.npid = 0" (field_expression "bgpids.npid" identifier . field_identifier) = number_literal) ;) })) (labeled_statement "LAB_0006fd20:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);" statement_identifier : (expression_statement "sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);" (call_expression "sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0)" identifier (argument_list "(2,(sigset_t *)&oset,(sigset_t *)0x0)" ( number_literal , (cast_expression "(sigset_t *)&oset" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&oset" & identifier)) , (cast_expression "(sigset_t *)0x0" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ))) ;)) (if_statement "if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" if (parenthesized_expression "(iVar1 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "iVar1 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" { comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) })) (return_statement "return;" return ;) })))
(translation_unit "void delete_all_jobs(int param_1)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }\n  return;\n}\n\n" (function_definition "void delete_all_jobs(int param_1)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }\n  return;\n}" primitive_type (function_declarator "delete_all_jobs(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "sigset_t local_120;" type_identifier identifier ;) (declaration "sigset_t local_a0;" type_identifier identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x6fc59;" (assignment_expression "uStack_14 = 0x6fc59" identifier = number_literal) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "sigemptyset(&local_120);" (call_expression "sigemptyset(&local_120)" identifier (argument_list "(&local_120)" ( (pointer_expression "&local_120" & identifier) ))) ;) (expression_statement "sigaddset(&local_120,0x11);" (call_expression "sigaddset(&local_120,0x11)" identifier (argument_list "(&local_120,0x11)" ( (pointer_expression "&local_120" & identifier) , number_literal ))) ;) (expression_statement "sigemptyset(&local_a0);" (call_expression "sigemptyset(&local_a0)" identifier (argument_list "(&local_a0)" ( (pointer_expression "&local_a0" & identifier) ))) ;) (expression_statement "sigprocmask(0,&local_120,&local_a0);" (call_expression "sigprocmask(0,&local_120,&local_a0)" identifier (argument_list "(0,&local_120,&local_a0)" ( number_literal , (pointer_expression "&local_120" & identifier) , (pointer_expression "&local_a0" & identifier) ))) ;) (if_statement "if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" if (parenthesized_expression "(DAT_001727d8 == 0)" ( (binary_expression "DAT_001727d8 == 0" identifier == number_literal) )) (compound_statement "{\n    if (param_1 != 0) goto LAB_0006fd20;\n  }" { (if_statement "if (param_1 != 0) goto LAB_0006fd20;" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) }) (else_clause "else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" else (compound_statement "{\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" { (expression_statement "DAT_001727f0 = 0xffffffff;" (assignment_expression "DAT_001727f0 = 0xffffffff" identifier = number_literal) ;) (expression_statement "DAT_001727ec = 0xffffffff;" (assignment_expression "DAT_001727ec = 0xffffffff" identifier = number_literal) ;) (if_statement "if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" if (parenthesized_expression "(DAT_001727d8 < 1)" ( (binary_expression "DAT_001727d8 < 1" identifier < number_literal) )) (compound_statement "{\n      if (param_1 != 0) goto LAB_0006fd20;\n    }" { (if_statement "if (param_1 != 0) goto LAB_0006fd20;" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) }) (else_clause "else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" else (compound_statement "{\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" { (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) (if_statement "if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }" if (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) )) (compound_statement "{\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (do_statement "do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);" do (compound_statement "{\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" { (while_statement "while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }" while (parenthesized_expression "(((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0)))" ( (parenthesized_expression "((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))" ( (binary_expression "(iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0)" (parenthesized_expression "(iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1))" ( (comma_expression "iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)" (assignment_expression "iVar1 = *(int *)((int)jobs + iVar3 * 4)" identifier = (pointer_expression "*(int *)((int)jobs + iVar3 * 4)" * (cast_expression "(int *)((int)jobs + iVar3 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)jobs + iVar3 * 4)" ( (binary_expression "(int)jobs + iVar3 * 4" (cast_expression "(int)jobs" ( (type_descriptor "int" primitive_type) ) identifier) + (binary_expression "iVar3 * 4" identifier * number_literal)) ))))) , (binary_expression "iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)" (binary_expression "iVar1 == 0" identifier == number_literal) || (parenthesized_expression "(*(int *)(iVar1 + 0xc) != 1)" ( (binary_expression "*(int *)(iVar1 + 0xc) != 1" (pointer_expression "*(int *)(iVar1 + 0xc)" * (cast_expression "(int *)(iVar1 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0xc)" ( (binary_expression "iVar1 + 0xc" identifier + number_literal) )))) != number_literal) )))) )) || (parenthesized_expression "(DAT_00179020 != 0)" ( (binary_expression "DAT_00179020 != 0" identifier != number_literal) ))) )) )) (compound_statement "{\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }" { (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (if_statement "if (iVar2 <= iVar3) goto LAB_0006fd20;" if (parenthesized_expression "(iVar2 <= iVar3)" ( (binary_expression "iVar2 <= iVar3" identifier <= identifier) )) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;)) })) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (expression_statement "FUN_00068fb0();" (call_expression "FUN_00068fb0()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) }) while (parenthesized_expression "(iVar3 < DAT_001727d8)" ( (binary_expression "iVar3 < DAT_001727d8" identifier < identifier) )) ;) (goto_statement "goto LAB_0006fd20;" goto statement_identifier ;) })) (do_statement "do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);" do (compound_statement "{\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      }" { (if_statement "if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" if (parenthesized_expression "((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0))" ( (binary_expression "(*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)" (parenthesized_expression "(*(int *)((int)jobs + param_1 * 4) != 0)" ( (binary_expression "*(int *)((int)jobs + param_1 * 4) != 0" (pointer_expression "*(int *)((int)jobs + param_1 * 4)" * (cast_expression "(int *)((int)jobs + param_1 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)jobs + param_1 * 4)" ( (binary_expression "(int)jobs + param_1 * 4" (cast_expression "(int)jobs" ( (type_descriptor "int" primitive_type) ) identifier) + (binary_expression "param_1 * 4" identifier * number_literal)) )))) != number_literal) )) && (parenthesized_expression "(DAT_00179020 == 0)" ( (binary_expression "DAT_00179020 == 0" identifier == number_literal) ))) )) (compound_statement "{\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" { (expression_statement "FUN_00068fb0();" (call_expression "FUN_00068fb0()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) })) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_1 < iVar2)" ( (binary_expression "param_1 < iVar2" identifier < identifier) )) ;) }))) (expression_statement "free(jobs);" (call_expression "free(jobs)" identifier (argument_list "(jobs)" ( identifier ))) ;) (expression_statement "DAT_001727d8 = 0;" (assignment_expression "DAT_001727d8 = 0" identifier = number_literal) ;) (expression_statement "DAT_001727e4 = 0;" (assignment_expression "DAT_001727e4 = 0" identifier = number_literal) ;) (expression_statement "DAT_001727dc = 0;" (assignment_expression "DAT_001727dc = 0" identifier = number_literal) ;) (expression_statement "DAT_001727e0 = 0;" (assignment_expression "DAT_001727e0 = 0" identifier = number_literal) ;) }))) (if_statement "if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }" if (parenthesized_expression "((bgpids != (void *)0x0) && (DAT_00177f00 != 0))" ( (binary_expression "(bgpids != (void *)0x0) && (DAT_00177f00 != 0)" (parenthesized_expression "(bgpids != (void *)0x0)" ( (binary_expression "bgpids != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(DAT_00177f00 != 0)" ( (binary_expression "DAT_00177f00 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }" { (expression_statement "free(bgpids);" (call_expression "free(bgpids)" identifier (argument_list "(bgpids)" ( identifier ))) ;) (expression_statement "bgpids = (void *)0x0;" (assignment_expression "bgpids = (void *)0x0" identifier = (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "DAT_00177f00 = 0;" (assignment_expression "DAT_00177f00 = 0" identifier = number_literal) ;) (expression_statement "DAT_00177efc = 0;" (assignment_expression "DAT_00177efc = 0" identifier = number_literal) ;) (expression_statement "DAT_00177f04 = 0;" (assignment_expression "DAT_00177f04 = 0" identifier = number_literal) ;) })) (labeled_statement "LAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);" statement_identifier : (expression_statement "sigprocmask(2,&local_a0,(sigset_t *)0x0);" (call_expression "sigprocmask(2,&local_a0,(sigset_t *)0x0)" identifier (argument_list "(2,&local_a0,(sigset_t *)0x0)" ( number_literal , (pointer_expression "&local_a0" & identifier) , (cast_expression "(sigset_t *)0x0" ( (type_descriptor "sigset_t *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ))) ;)) (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }" if (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    \n    FUN_0010f8b0();\n  }" { (expression_statement "FUN_0010f8b0();" (call_expression "FUN_0010f8b0()" identifier (argument_list "()" ( ))) ;) })) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) ))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , LIT ))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) ))) ;) (expression_statement (call_expression IDENT (argument_list ( LIT , (pointer_expression & IDENT) , (pointer_expression & IDENT) ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (goto_statement goto statement_identifier ;)) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (goto_statement goto statement_identifier ;)) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (do_statement do (compound_statement { (while_statement while (parenthesized_expression ( (parenthesized_expression ( (binary_expression (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) + (binary_expression IDENT * LIT)) ))))) , (binary_expression (binary_expression IDENT == LIT) || (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) )))) )) || (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (goto_statement goto statement_identifier ;)) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression IDENT < IDENT) )) ;) (goto_statement goto statement_identifier ;) })) (do_statement do (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) + (binary_expression IDENT * LIT)) )))) != LIT) )) && (parenthesized_expression ( (binary_expression IDENT == LIT) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < IDENT) )) ;) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) })) (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( LIT , (pointer_expression & IDENT) , (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT) ))) ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (return_statement return ;) })))
(function_definition "void delete_all_jobs(int param_1)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }\n  return;\n}" (primitive_type "void") (function_declarator "delete_all_jobs(int param_1)" (identifier "delete_all_jobs") (parameter_list "(int param_1)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) () ")"))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int in_GS_OFFSET;\n  sigset_t local_120;\n  sigset_t local_a0;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x6fc59;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  sigemptyset(&local_120);\n  sigaddset(&local_120,0x11);\n  sigemptyset(&local_a0);\n  sigprocmask(0,&local_120,&local_a0);\n  if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }\n  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }\nLAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }\n  return;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "sigset_t local_120;" (type_identifier "sigset_t") (identifier "local_120") (; ";")) (declaration "sigset_t local_a0;" (type_identifier "sigset_t") (identifier "local_a0") (; ";")) (declaration "int local_20;" (primitive_type "int") (identifier "local_20") (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x6fc59;" (assignment_expression "uStack_14 = 0x6fc59" (identifier "uStack_14") (= "=") (number_literal "0x6fc59")) (; ";")) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (= "=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (expression_statement "sigemptyset(&local_120);" (call_expression "sigemptyset(&local_120)" (identifier "sigemptyset") (argument_list "(&local_120)" (( "(") (pointer_expression "&local_120" (& "&") (identifier "local_120")) () ")"))) (; ";")) (expression_statement "sigaddset(&local_120,0x11);" (call_expression "sigaddset(&local_120,0x11)" (identifier "sigaddset") (argument_list "(&local_120,0x11)" (( "(") (pointer_expression "&local_120" (& "&") (identifier "local_120")) (, ",") (number_literal "0x11") () ")"))) (; ";")) (expression_statement "sigemptyset(&local_a0);" (call_expression "sigemptyset(&local_a0)" (identifier "sigemptyset") (argument_list "(&local_a0)" (( "(") (pointer_expression "&local_a0" (& "&") (identifier "local_a0")) () ")"))) (; ";")) (expression_statement "sigprocmask(0,&local_120,&local_a0);" (call_expression "sigprocmask(0,&local_120,&local_a0)" (identifier "sigprocmask") (argument_list "(0,&local_120,&local_a0)" (( "(") (number_literal "0") (, ",") (pointer_expression "&local_120" (& "&") (identifier "local_120")) (, ",") (pointer_expression "&local_a0" (& "&") (identifier "local_a0")) () ")"))) (; ";")) (if_statement "if (DAT_001727d8 == 0) {\n    if (param_1 != 0) goto LAB_0006fd20;\n  }\n  else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" (if "if") (parenthesized_expression "(DAT_001727d8 == 0)" (( "(") (binary_expression "DAT_001727d8 == 0" (identifier "DAT_001727d8") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if (param_1 != 0) goto LAB_0006fd20;\n  }" ({ "{") (if_statement "if (param_1 != 0) goto LAB_0006fd20;" (if "if") (parenthesized_expression "(param_1 != 0)" (( "(") (binary_expression "param_1 != 0" (identifier "param_1") (!= "!=") (number_literal "0")) () ")")) (goto_statement "goto LAB_0006fd20;" (goto "goto") (statement_identifier "LAB_0006fd20") (; ";"))) (} "}")) (else_clause "else {\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" (else "else") (compound_statement "{\n    DAT_001727f0 = 0xffffffff;\n    DAT_001727ec = 0xffffffff;\n    if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }\n    free(jobs);\n    DAT_001727d8 = 0;\n    DAT_001727e4 = 0;\n    DAT_001727dc = 0;\n    DAT_001727e0 = 0;\n  }" ({ "{") (expression_statement "DAT_001727f0 = 0xffffffff;" (assignment_expression "DAT_001727f0 = 0xffffffff" (identifier "DAT_001727f0") (= "=") (number_literal "0xffffffff")) (; ";")) (expression_statement "DAT_001727ec = 0xffffffff;" (assignment_expression "DAT_001727ec = 0xffffffff" (identifier "DAT_001727ec") (= "=") (number_literal "0xffffffff")) (; ";")) (if_statement "if (DAT_001727d8 < 1) {\n      if (param_1 != 0) goto LAB_0006fd20;\n    }\n    else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" (if "if") (parenthesized_expression "(DAT_001727d8 < 1)" (( "(") (binary_expression "DAT_001727d8 < 1" (identifier "DAT_001727d8") (< "<") (number_literal "1")) () ")")) (compound_statement "{\n      if (param_1 != 0) goto LAB_0006fd20;\n    }" ({ "{") (if_statement "if (param_1 != 0) goto LAB_0006fd20;" (if "if") (parenthesized_expression "(param_1 != 0)" (( "(") (binary_expression "param_1 != 0" (identifier "param_1") (!= "!=") (number_literal "0")) () ")")) (goto_statement "goto LAB_0006fd20;" (goto "goto") (statement_identifier "LAB_0006fd20") (; ";"))) (} "}")) (else_clause "else {\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" (else "else") (compound_statement "{\n      iVar2 = DAT_001727d8;\n      if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }\n      do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);\n    }" ({ "{") (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" (identifier "iVar2") (= "=") (identifier "DAT_001727d8")) (; ";")) (if_statement "if (param_1 != 0) {\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }" (if "if") (parenthesized_expression "(param_1 != 0)" (( "(") (binary_expression "param_1 != 0" (identifier "param_1") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        iVar3 = 0;\n        do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);\n        goto LAB_0006fd20;\n      }" ({ "{") (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" (identifier "iVar3") (= "=") (number_literal "0")) (; ";")) (do_statement "do {\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        } while (iVar3 < DAT_001727d8);" (do "do") (compound_statement "{\n          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }\n          iVar3 = iVar3 + 1;\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" ({ "{") (while_statement "while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }" (while "while") (parenthesized_expression "(((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0)))" (( "(") (parenthesized_expression "((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))" (( "(") (binary_expression "(iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0)" (parenthesized_expression "(iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1))" (( "(") (comma_expression "iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)" (assignment_expression "iVar1 = *(int *)((int)jobs + iVar3 * 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)((int)jobs + iVar3 * 4)" (* "*") (cast_expression "(int *)((int)jobs + iVar3 * 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)jobs + iVar3 * 4)" (( "(") (binary_expression "(int)jobs + iVar3 * 4" (cast_expression "(int)jobs" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "jobs")) (+ "+") (binary_expression "iVar3 * 4" (identifier "iVar3") (* "*") (number_literal "4"))) () ")"))))) (, ",") (binary_expression "iVar1 == 0 ||\n                  (*(int *)(iVar1 + 0xc) != 1)" (binary_expression "iVar1 == 0" (identifier "iVar1") (== "==") (number_literal "0")) (|| "||") (parenthesized_expression "(*(int *)(iVar1 + 0xc) != 1)" (( "(") (binary_expression "*(int *)(iVar1 + 0xc) != 1" (pointer_expression "*(int *)(iVar1 + 0xc)" (* "*") (cast_expression "(int *)(iVar1 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0xc)" (( "(") (binary_expression "iVar1 + 0xc" (identifier "iVar1") (+ "+") (number_literal "0xc")) () ")")))) (!= "!=") (number_literal "1")) () ")")))) () ")")) (|| "||") (parenthesized_expression "(DAT_00179020 != 0)" (( "(") (binary_expression "DAT_00179020 != 0" (identifier "DAT_00179020") (!= "!=") (number_literal "0")) () ")"))) () ")")) () ")")) (compound_statement "{\n            iVar3 = iVar3 + 1;\n            if (iVar2 <= iVar3) goto LAB_0006fd20;\n          }" ({ "{") (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" (identifier "iVar3") (= "=") (binary_expression "iVar3 + 1" (identifier "iVar3") (+ "+") (number_literal "1"))) (; ";")) (if_statement "if (iVar2 <= iVar3) goto LAB_0006fd20;" (if "if") (parenthesized_expression "(iVar2 <= iVar3)" (( "(") (binary_expression "iVar2 <= iVar3" (identifier "iVar2") (<= "<=") (identifier "iVar3")) () ")")) (goto_statement "goto LAB_0006fd20;" (goto "goto") (statement_identifier "LAB_0006fd20") (; ";"))) (} "}"))) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" (identifier "iVar3") (= "=") (binary_expression "iVar3 + 1" (identifier "iVar3") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "FUN_00068fb0();" (call_expression "FUN_00068fb0()" (identifier "FUN_00068fb0") (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" (identifier "iVar2") (= "=") (identifier "DAT_001727d8")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar3 < DAT_001727d8)" (( "(") (binary_expression "iVar3 < DAT_001727d8" (identifier "iVar3") (< "<") (identifier "DAT_001727d8")) () ")")) (; ";")) (goto_statement "goto LAB_0006fd20;" (goto "goto") (statement_identifier "LAB_0006fd20") (; ";")) (} "}"))) (do_statement "do {\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      } while (param_1 < iVar2);" (do "do") (compound_statement "{\n        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }\n        param_1 = param_1 + 1;\n      }" ({ "{") (if_statement "if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" (if "if") (parenthesized_expression "((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0))" (( "(") (binary_expression "(*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)" (parenthesized_expression "(*(int *)((int)jobs + param_1 * 4) != 0)" (( "(") (binary_expression "*(int *)((int)jobs + param_1 * 4) != 0" (pointer_expression "*(int *)((int)jobs + param_1 * 4)" (* "*") (cast_expression "(int *)((int)jobs + param_1 * 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)jobs + param_1 * 4)" (( "(") (binary_expression "(int)jobs + param_1 * 4" (cast_expression "(int)jobs" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "jobs")) (+ "+") (binary_expression "param_1 * 4" (identifier "param_1") (* "*") (number_literal "4"))) () ")")))) (!= "!=") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "(DAT_00179020 == 0)" (( "(") (binary_expression "DAT_00179020 == 0" (identifier "DAT_00179020") (== "==") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n          FUN_00068fb0();\n          iVar2 = DAT_001727d8;\n        }" ({ "{") (expression_statement "FUN_00068fb0();" (call_expression "FUN_00068fb0()" (identifier "FUN_00068fb0") (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" (identifier "iVar2") (= "=") (identifier "DAT_001727d8")) (; ";")) (} "}"))) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" (identifier "param_1") (= "=") (binary_expression "param_1 + 1" (identifier "param_1") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(param_1 < iVar2)" (( "(") (binary_expression "param_1 < iVar2" (identifier "param_1") (< "<") (identifier "iVar2")) () ")")) (; ";")) (} "}")))) (expression_statement "free(jobs);" (call_expression "free(jobs)" (identifier "free") (argument_list "(jobs)" (( "(") (identifier "jobs") () ")"))) (; ";")) (expression_statement "DAT_001727d8 = 0;" (assignment_expression "DAT_001727d8 = 0" (identifier "DAT_001727d8") (= "=") (number_literal "0")) (; ";")) (expression_statement "DAT_001727e4 = 0;" (assignment_expression "DAT_001727e4 = 0" (identifier "DAT_001727e4") (= "=") (number_literal "0")) (; ";")) (expression_statement "DAT_001727dc = 0;" (assignment_expression "DAT_001727dc = 0" (identifier "DAT_001727dc") (= "=") (number_literal "0")) (; ";")) (expression_statement "DAT_001727e0 = 0;" (assignment_expression "DAT_001727e0 = 0" (identifier "DAT_001727e0") (= "=") (number_literal "0")) (; ";")) (} "}")))) (if_statement "if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }" (if "if") (parenthesized_expression "((bgpids != (void *)0x0) && (DAT_00177f00 != 0))" (( "(") (binary_expression "(bgpids != (void *)0x0) && (DAT_00177f00 != 0)" (parenthesized_expression "(bgpids != (void *)0x0)" (( "(") (binary_expression "bgpids != (void *)0x0" (identifier "bgpids") (!= "!=") (cast_expression "(void *)0x0" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(DAT_00177f00 != 0)" (( "(") (binary_expression "DAT_00177f00 != 0" (identifier "DAT_00177f00") (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n    free(bgpids);\n    bgpids = (void *)0x0;\n    DAT_00177f00 = 0;\n    DAT_00177efc = 0;\n    DAT_00177f04 = 0;\n  }" ({ "{") (expression_statement "free(bgpids);" (call_expression "free(bgpids)" (identifier "free") (argument_list "(bgpids)" (( "(") (identifier "bgpids") () ")"))) (; ";")) (expression_statement "bgpids = (void *)0x0;" (assignment_expression "bgpids = (void *)0x0" (identifier "bgpids") (= "=") (cast_expression "(void *)0x0" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";")) (expression_statement "DAT_00177f00 = 0;" (assignment_expression "DAT_00177f00 = 0" (identifier "DAT_00177f00") (= "=") (number_literal "0")) (; ";")) (expression_statement "DAT_00177efc = 0;" (assignment_expression "DAT_00177efc = 0" (identifier "DAT_00177efc") (= "=") (number_literal "0")) (; ";")) (expression_statement "DAT_00177f04 = 0;" (assignment_expression "DAT_00177f04 = 0" (identifier "DAT_00177f04") (= "=") (number_literal "0")) (; ";")) (} "}"))) (labeled_statement "LAB_0006fd20:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);" (statement_identifier "LAB_0006fd20") (: ":") (expression_statement "sigprocmask(2,&local_a0,(sigset_t *)0x0);" (call_expression "sigprocmask(2,&local_a0,(sigset_t *)0x0)" (identifier "sigprocmask") (argument_list "(2,&local_a0,(sigset_t *)0x0)" (( "(") (number_literal "2") (, ",") (pointer_expression "&local_a0" (& "&") (identifier "local_a0")) (, ",") (cast_expression "(sigset_t *)0x0" (( "(") (type_descriptor "sigset_t *" (type_identifier "sigset_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0")) () ")"))) (; ";"))) (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0010f8b0();\n  }" (if "if") (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" (( "(") (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (!= "!=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n                    \n    FUN_0010f8b0();\n  }" ({ "{") (expression_statement "FUN_0010f8b0();" (call_expression "FUN_0010f8b0()" (identifier "FUN_0010f8b0") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (return_statement "return;" (return "return") (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Unknown calling convention */

void function_1(int var_5)

{
  int var_13;
  int var_9;
  int var_8;
  int var_11;
  int var_1;
  type_1 set;
  type_1 oset;
  
  var_13 = *(int *)(var_1 + 0x14);
  var_2((type_1 *)&set);
  var_3((type_1 *)&set,0x11);
  var_2((type_1 *)&oset);
  var_4(0,(type_1 *)&set,(type_1 *)&oset);
  if (js.j_jobslots == 0) {
    if (var_5 != 0) goto LAB_0006fd20;
  }
  else {
    js.j_previous = -1;
    js.j_current = -1;
    if (js.j_jobslots < 1) {
      if (var_5 != 0) goto LAB_0006fd20;
    }
    else {
      var_9 = js.j_jobslots;
      if (var_5 != 0) {
        var_8 = 0;
        do {
          while (((jobs[var_8] == (type_2 *)0x0 || (jobs[var_8]->state != var_6)) ||
                 (var_7 != 0))) {
            var_8 = var_8 + 1;
            if (var_9 <= var_8) goto LAB_0006fd20;
          }
          var_11 = var_8 + 1;
          var_10(var_8,3);
          var_9 = js.j_jobslots;
          var_8 = var_11;
        } while (var_11 < js.j_jobslots);
        goto LAB_0006fd20;
      }
      do {
        if ((jobs[var_5] != (type_2 *)0x0) && (var_7 == 0)) {
          var_10(var_5,3);
          var_9 = js.j_jobslots;
        }
        var_5 = var_5 + 1;
      } while (var_5 < var_9);
    }
    var_12(jobs);
    js.j_jobslots = 0;
    js.j_njobs = 0;
    js.j_lastj = 0;
    js.j_firstj = 0;
  }
  if ((bgpids.storage != (type_3 *)0x0) && (bgpids.nalloc != 0)) {
    var_12(bgpids.storage);
    bgpids.storage = (type_3 *)0x0;
    bgpids.nalloc = 0;
    bgpids.head = 0;
    bgpids.npid = 0;
  }
LAB_0006fd20:
  var_4(2,(type_1 *)&oset,(type_1 *)0x0);
  if (var_13 != *(int *)(var_1 + 0x14)) {
                    /* WARNING: Subroutine does not return */
    var_14();
  }
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (pointer_expression argument: (identifier)) (pointer_expression argument: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (do_statement body: (compound_statement (while_statement condition: (parenthesized_expression (parenthesized_expression (binary_expression left: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (binary_expression left: (identifier) right: (number_literal))))))) right: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (goto_statement label: (statement_identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier)))) (goto_statement label: (statement_identifier)))) (do_statement body: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (binary_expression left: (identifier) right: (number_literal)))))) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (expression_statement (assignment_expression left: (identifier) right: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))))) (labeled_statement label: (statement_identifier) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (pointer_expression argument: (identifier)) (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (return_statement))))

/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

void MASKED(int param_1)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int in_GS_OFFSET;
  sigset_t local_120;
  sigset_t local_a0;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x6fc59;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  sigemptyset(&local_120);
  sigaddset(&local_120,0x11);
  sigemptyset(&local_a0);
  sigprocmask(0,&local_120,&local_a0);
  if (DAT_001727d8 == 0) {
    if (param_1 != 0) goto LAB_0006fd20;
  }
  else {
    DAT_001727f0 = 0xffffffff;
    DAT_001727ec = 0xffffffff;
    if (DAT_001727d8 < 1) {
      if (param_1 != 0) goto LAB_0006fd20;
    }
    else {
      iVar2 = DAT_001727d8;
      if (param_1 != 0) {
        iVar3 = 0;
        do {
          while (((iVar1 = *(int *)((int)jobs + iVar3 * 4), iVar1 == 0 ||
                  (*(int *)(iVar1 + 0xc) != 1)) || (DAT_00179020 != 0))) {
            iVar3 = iVar3 + 1;
            if (iVar2 <= iVar3) goto LAB_0006fd20;
          }
          iVar3 = iVar3 + 1;
          FUN_00068fb0();
          iVar2 = DAT_001727d8;
        } while (iVar3 < DAT_001727d8);
        goto LAB_0006fd20;
      }
      do {
        if ((*(int *)((int)jobs + param_1 * 4) != 0) && (DAT_00179020 == 0)) {
          FUN_00068fb0();
          iVar2 = DAT_001727d8;
        }
        param_1 = param_1 + 1;
      } while (param_1 < iVar2);
    }
    free(jobs);
    DAT_001727d8 = 0;
    DAT_001727e4 = 0;
    DAT_001727dc = 0;
    DAT_001727e0 = 0;
  }
  if ((bgpids != (void *)0x0) && (DAT_00177f00 != 0)) {
    free(bgpids);
    bgpids = (void *)0x0;
    DAT_00177f00 = 0;
    DAT_00177efc = 0;
    DAT_00177f04 = 0;
  }
LAB_0006fd20:
  sigprocmask(2,&local_a0,(sigset_t *)0x0);
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_0010f8b0();
  }
  return;
}

