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

int __regparm3 map_over_jobs(sh_job_map_func_t *func,int arg1,int arg2)

{
  int iVar1;
  JOB *pJVar2;
  undefined *puVar3;
  JOB **ppJVar4;
  int iVar5;
  int iVar6;
  int iVar7;
  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);
  puVar3 = PTR_stdout_00171f70;
  if (0 < js.j_jobslots) {
    iVar6 = 0;
    iVar5 = js.j_jobslots;
    if (arg1 == -1) {
      iVar6 = 0;
      ppJVar4 = jobs;
      do {
        pJVar2 = ppJVar4[iVar6];
        while (pJVar2 != (JOB *)0x0) {
          iVar7 = iVar6 + 1;
          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);
          if (js.j_jobslots <= iVar7) goto LAB_000687b2;
          ppJVar4 = jobs;
          iVar5 = js.j_jobslots;
          iVar6 = iVar7;
          pJVar2 = jobs[iVar7];
        }
        iVar6 = iVar6 + 1;
      } while (iVar6 < iVar5);
    }
    else {
      do {
        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {
          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);
          iVar5 = js.j_jobslots;
        }
        iVar6 = iVar6 + 1;
      } while (iVar6 < iVar5);
    }
  }
LAB_000687b2:
  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);
  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {
    return 0;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail_local();
}



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

undefined4 __regparm3 FUN_00068700(undefined4 param_1,int param_2)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  int in_GS_OFFSET;
  sigset_t local_120;
  sigset_t local_a0;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x6870b;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  sigemptyset(&local_120);
  sigaddset(&local_120,0x11);
  sigemptyset(&local_a0);
  sigprocmask(0,&local_120,&local_a0);
  if (0 < DAT_001727d8) {
    iVar3 = 0;
    iVar2 = DAT_001727d8;
    if (param_2 == -1) {
      iVar4 = 0;
      iVar2 = jobs;
      iVar3 = DAT_001727d8;
      do {
        iVar1 = *(int *)(iVar2 + iVar4 * 4);
        while (iVar1 != 0) {
          iVar4 = iVar4 + 1;
          FUN_00067e90();
          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;
          iVar2 = jobs;
          iVar3 = DAT_001727d8;
          iVar1 = *(int *)(jobs + iVar4 * 4);
        }
        iVar4 = iVar4 + 1;
      } while (iVar4 < iVar3);
    }
    else {
      do {
        iVar4 = *(int *)(jobs + iVar3 * 4);
        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {
          FUN_00067e90();
          iVar2 = DAT_001727d8;
        }
        iVar3 = iVar3 + 1;
      } while (iVar3 < iVar2);
    }
  }
LAB_000687b2:
  sigprocmask(2,&local_a0,(sigset_t *)0x0);
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return 0;
  }
                    /* WARNING: Subroutine does not return */
  FUN_0010f8b0();
}


PUSH EBP
PUSH EDI
MOV EDI,EDX
PUSH ESI
PUSH EBX
CALL 0x000312b0
ADD EBX,0x1098f5
SUB ESP,0x138
MOV dword ptr [ESP + 0x14],EAX
LEA ESI,[ESP + 0x28]
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0x128],EAX
XOR EAX,EAX
PUSH ESI
CALL 0x0002ea40
POP EBP
POP EAX
PUSH 0x11
PUSH ESI
CALL 0x0002e810
POP EAX
LEA EBP,[ESP + 0xa8]
PUSH EBP
CALL 0x0002ea40
ADD ESP,0xc
PUSH EBP
PUSH ESI
PUSH 0x0
CALL 0x0002e1a0
MOV EDX,dword ptr [EBX + 0x7d8]
ADD ESP,0x10
TEST EDX,EDX
JLE 0x000687b2
XOR ESI,ESI
CMP EDI,-0x1
JZ 0x000687e0
MOV EAX,dword ptr [EBX + 0xffffff70]
MOV dword ptr [ESP + 0xc],EBP
MOV EBP,dword ptr [ESP + 0x8]
MOV dword ptr [ESP + 0x4],EAX
NOP
MOV EAX,dword ptr [EBX + 0x5ef4]
MOV EAX,dword ptr [EAX + ESI*0x4]
TEST EAX,EAX
JZ 0x000687a7
CMP EDI,dword ptr [EAX + 0xc]
JNZ 0x000687a7
MOV EAX,dword ptr [ESP + 0x4]
MOV EDX,EBP
MOV ECX,dword ptr [EAX]
MOV EAX,ESI
CALL 0x00067e90
MOV EDX,dword ptr [EBX + 0x7d8]
ADD ESI,0x1
CMP EDX,ESI
JG 0x00068780
MOV EBP,dword ptr [ESP + 0xc]
SUB ESP,0x4
PUSH 0x0
PUSH EBP
PUSH 0x2
CALL 0x0002e1a0
ADD ESP,0x10
XOR EAX,EAX
MOV ECX,dword ptr [ESP + 0x11c]
XOR ECX,dword ptr GS:[0x14]
JNZ 0x00068827
ADD ESP,0x12c
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV EAX,dword ptr [EBX + 0x5ef4]
MOV EDI,dword ptr [EBX + 0xffffff70]
LEA ESI,[ESI]
MOV ECX,dword ptr [EAX + ESI*0x4]
TEST ECX,ECX
JZ 0x0006881e
MOV EDX,dword ptr [ESP + 0x8]
MOV ECX,dword ptr [EDI]
MOV EAX,ESI
ADD ESI,0x1
CALL 0x00067e90
MOV EDX,dword ptr [EBX + 0x7d8]
CMP EDX,ESI
JLE 0x000687b2
MOV EAX,dword ptr [EBX + 0x5ef4]
MOV ECX,dword ptr [EAX + ESI*0x4]
TEST ECX,ECX
JNZ 0x000687f7
ADD ESI,0x1
CMP ESI,EDX
JL 0x000687f0
JMP 0x000687b2
CALL 0x0010f8b0
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nundefined4 __regparm3 FUN_00068700(undefined4 param_1,int param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0010f8b0();\n}\n\n" comment (function_definition "undefined4 __regparm3 FUN_00068700(undefined4 param_1,int param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0010f8b0();\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_00068700(undefined4 param_1,int param_2)" identifier (parameter_list "(undefined4 param_1,int param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0010f8b0();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" 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 = 0x6870b;" (assignment_expression "uStack_14 = 0x6870b" 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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }" if (parenthesized_expression "(0 < DAT_001727d8)" ( (binary_expression "0 < DAT_001727d8" number_literal < identifier) )) (compound_statement "{\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) (if_statement "if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" if (parenthesized_expression "(param_2 == -1)" ( (binary_expression "param_2 == -1" identifier == number_literal) )) (compound_statement "{\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }" { (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" identifier = number_literal) ;) (expression_statement "iVar2 = jobs;" (assignment_expression "iVar2 = jobs" identifier = identifier) ;) (expression_statement "iVar3 = DAT_001727d8;" (assignment_expression "iVar3 = DAT_001727d8" identifier = identifier) ;) (do_statement "do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);" do (compound_statement "{\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      }" { (expression_statement "iVar1 = *(int *)(iVar2 + iVar4 * 4);" (assignment_expression "iVar1 = *(int *)(iVar2 + iVar4 * 4)" identifier = (pointer_expression "*(int *)(iVar2 + iVar4 * 4)" * (cast_expression "(int *)(iVar2 + iVar4 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar2 + iVar4 * 4)" ( (binary_expression "iVar2 + iVar4 * 4" identifier + (binary_expression "iVar4 * 4" identifier * number_literal)) ))))) ;) (while_statement "while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }" while (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (compound_statement "{\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }" { (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) (expression_statement "FUN_00067e90();" (call_expression "FUN_00067e90()" identifier (argument_list "()" ( ))) ;) (if_statement "if (DAT_001727d8 <= iVar4) goto LAB_000687b2;" if (parenthesized_expression "(DAT_001727d8 <= iVar4)" ( (binary_expression "DAT_001727d8 <= iVar4" identifier <= identifier) )) (goto_statement "goto LAB_000687b2;" goto statement_identifier ;)) (expression_statement "iVar2 = jobs;" (assignment_expression "iVar2 = jobs" identifier = identifier) ;) (expression_statement "iVar3 = DAT_001727d8;" (assignment_expression "iVar3 = DAT_001727d8" identifier = identifier) ;) (expression_statement "iVar1 = *(int *)(jobs + iVar4 * 4);" (assignment_expression "iVar1 = *(int *)(jobs + iVar4 * 4)" identifier = (pointer_expression "*(int *)(jobs + iVar4 * 4)" * (cast_expression "(int *)(jobs + iVar4 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(jobs + iVar4 * 4)" ( (binary_expression "jobs + iVar4 * 4" identifier + (binary_expression "iVar4 * 4" identifier * number_literal)) ))))) ;) })) (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar4 < iVar3)" ( (binary_expression "iVar4 < iVar3" identifier < identifier) )) ;) }) (else_clause "else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" else (compound_statement "{\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" { (do_statement "do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);" do (compound_statement "{\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      }" { (expression_statement "iVar4 = *(int *)(jobs + iVar3 * 4);" (assignment_expression "iVar4 = *(int *)(jobs + iVar3 * 4)" identifier = (pointer_expression "*(int *)(jobs + iVar3 * 4)" * (cast_expression "(int *)(jobs + iVar3 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(jobs + iVar3 * 4)" ( (binary_expression "jobs + iVar3 * 4" identifier + (binary_expression "iVar3 * 4" identifier * number_literal)) ))))) ;) (if_statement "if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }" if (parenthesized_expression "((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc)))" ( (binary_expression "(iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))" (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) && (parenthesized_expression "(param_2 == *(int *)(iVar4 + 0xc))" ( (binary_expression "param_2 == *(int *)(iVar4 + 0xc)" identifier == (pointer_expression "*(int *)(iVar4 + 0xc)" * (cast_expression "(int *)(iVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0xc)" ( (binary_expression "iVar4 + 0xc" identifier + number_literal) ))))) ))) )) (compound_statement "{\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }" { (expression_statement "FUN_00067e90();" (call_expression "FUN_00067e90()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) })) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar3 < iVar2)" ( (binary_expression "iVar3 < iVar2" identifier < identifier) )) ;) }))) })) (labeled_statement "LAB_000687b2:\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    return 0;\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    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) comment (expression_statement "FUN_0010f8b0();" (call_expression "FUN_0010f8b0()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint __regparm3 map_over_jobs(sh_job_map_func_t *func,int arg1,int arg2)\n\n{\n  int iVar1;\n  JOB *pJVar2;\n  undefined *puVar3;\n  JOB **ppJVar4;\n  int iVar5;\n  int iVar6;\n  int iVar7;\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  puVar3 = PTR_stdout_00171f70;\n  if (0 < js.j_jobslots) {\n    iVar6 = 0;\n    iVar5 = js.j_jobslots;\n    if (arg1 == -1) {\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n    else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}\n\n" comment (function_definition "int __regparm3 map_over_jobs(sh_job_map_func_t *func,int arg1,int arg2)\n\n{\n  int iVar1;\n  JOB *pJVar2;\n  undefined *puVar3;\n  JOB **ppJVar4;\n  int iVar5;\n  int iVar6;\n  int iVar7;\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  puVar3 = PTR_stdout_00171f70;\n  if (0 < js.j_jobslots) {\n    iVar6 = 0;\n    iVar5 = js.j_jobslots;\n    if (arg1 == -1) {\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n    else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "map_over_jobs(sh_job_map_func_t *func,int arg1,int arg2)" identifier (parameter_list "(sh_job_map_func_t *func,int arg1,int arg2)" ( (parameter_declaration "sh_job_map_func_t *func" type_identifier (pointer_declarator "*func" * identifier)) , (parameter_declaration "int arg1" primitive_type identifier) , (parameter_declaration "int arg2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  JOB *pJVar2;\n  undefined *puVar3;\n  JOB **ppJVar4;\n  int iVar5;\n  int iVar6;\n  int iVar7;\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  puVar3 = PTR_stdout_00171f70;\n  if (0 < js.j_jobslots) {\n    iVar6 = 0;\n    iVar5 = js.j_jobslots;\n    if (arg1 == -1) {\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n    else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,(sigset_t *)&oset,(sigset_t *)0x0);\n  if (iVar1 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "JOB *pJVar2;" type_identifier (pointer_declarator "*pJVar2" * identifier) ;) (declaration "undefined *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "JOB **ppJVar4;" type_identifier (pointer_declarator "**ppJVar4" * (pointer_declarator "*ppJVar4" * identifier)) ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "int iVar7;" 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)) ))) ;) (expression_statement "puVar3 = PTR_stdout_00171f70;" (assignment_expression "puVar3 = PTR_stdout_00171f70" identifier = identifier) ;) (if_statement "if (0 < js.j_jobslots) {\n    iVar6 = 0;\n    iVar5 = js.j_jobslots;\n    if (arg1 == -1) {\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n    else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n  }" if (parenthesized_expression "(0 < js.j_jobslots)" ( (binary_expression "0 < js.j_jobslots" number_literal < (field_expression "js.j_jobslots" identifier . field_identifier)) )) (compound_statement "{\n    iVar6 = 0;\n    iVar5 = js.j_jobslots;\n    if (arg1 == -1) {\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n    else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n  }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "iVar5 = js.j_jobslots;" (assignment_expression "iVar5 = js.j_jobslots" identifier = (field_expression "js.j_jobslots" identifier . field_identifier)) ;) (if_statement "if (arg1 == -1) {\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }\n    else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }" if (parenthesized_expression "(arg1 == -1)" ( (binary_expression "arg1 == -1" identifier == number_literal) )) (compound_statement "{\n      iVar6 = 0;\n      ppJVar4 = jobs;\n      do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "ppJVar4 = jobs;" (assignment_expression "ppJVar4 = jobs" identifier = identifier) ;) (do_statement "do {\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);" do (compound_statement "{\n        pJVar2 = ppJVar4[iVar6];\n        while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }\n        iVar6 = iVar6 + 1;\n      }" { (expression_statement "pJVar2 = ppJVar4[iVar6];" (assignment_expression "pJVar2 = ppJVar4[iVar6]" identifier = (subscript_expression "ppJVar4[iVar6]" identifier [ identifier ])) ;) (while_statement "while (pJVar2 != (JOB *)0x0) {\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }" while (parenthesized_expression "(pJVar2 != (JOB *)0x0)" ( (binary_expression "pJVar2 != (JOB *)0x0" identifier != (cast_expression "(JOB *)0x0" ( (type_descriptor "JOB *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n          iVar7 = iVar6 + 1;\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          if (js.j_jobslots <= iVar7) goto LAB_000687b2;\n          ppJVar4 = jobs;\n          iVar5 = js.j_jobslots;\n          iVar6 = iVar7;\n          pJVar2 = jobs[iVar7];\n        }" { (expression_statement "iVar7 = iVar6 + 1;" (assignment_expression "iVar7 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) (expression_statement "pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);" (call_expression "pretty_print_job(iVar6,(int)func,*(FILE **)puVar3)" identifier (argument_list "(iVar6,(int)func,*(FILE **)puVar3)" ( identifier , (cast_expression "(int)func" ( (type_descriptor "int" primitive_type) ) identifier) , (pointer_expression "*(FILE **)puVar3" * (cast_expression "(FILE **)puVar3" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) ))) ;) (if_statement "if (js.j_jobslots <= iVar7) goto LAB_000687b2;" if (parenthesized_expression "(js.j_jobslots <= iVar7)" ( (binary_expression "js.j_jobslots <= iVar7" (field_expression "js.j_jobslots" identifier . field_identifier) <= identifier) )) (goto_statement "goto LAB_000687b2;" goto statement_identifier ;)) (expression_statement "ppJVar4 = jobs;" (assignment_expression "ppJVar4 = jobs" identifier = identifier) ;) (expression_statement "iVar5 = js.j_jobslots;" (assignment_expression "iVar5 = js.j_jobslots" identifier = (field_expression "js.j_jobslots" identifier . field_identifier)) ;) (expression_statement "iVar6 = iVar7;" (assignment_expression "iVar6 = iVar7" identifier = identifier) ;) (expression_statement "pJVar2 = jobs[iVar7];" (assignment_expression "pJVar2 = jobs[iVar7]" identifier = (subscript_expression "jobs[iVar7]" identifier [ identifier ])) ;) })) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar6 < iVar5)" ( (binary_expression "iVar6 < iVar5" identifier < identifier) )) ;) }) (else_clause "else {\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }" else (compound_statement "{\n      do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);\n    }" { (do_statement "do {\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      } while (iVar6 < iVar5);" do (compound_statement "{\n        if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }\n        iVar6 = iVar6 + 1;\n      }" { (if_statement "if ((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)) {\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }" if (parenthesized_expression "((jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state))" ( (binary_expression "(jobs[iVar6] != (JOB *)0x0) && (arg1 == jobs[iVar6]->state)" (parenthesized_expression "(jobs[iVar6] != (JOB *)0x0)" ( (binary_expression "jobs[iVar6] != (JOB *)0x0" (subscript_expression "jobs[iVar6]" identifier [ identifier ]) != (cast_expression "(JOB *)0x0" ( (type_descriptor "JOB *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(arg1 == jobs[iVar6]->state)" ( (binary_expression "arg1 == jobs[iVar6]->state" identifier == (field_expression "jobs[iVar6]->state" (subscript_expression "jobs[iVar6]" identifier [ identifier ]) -> field_identifier)) ))) )) (compound_statement "{\n          pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);\n          iVar5 = js.j_jobslots;\n        }" { (expression_statement "pretty_print_job(iVar6,(int)func,*(FILE **)puVar3);" (call_expression "pretty_print_job(iVar6,(int)func,*(FILE **)puVar3)" identifier (argument_list "(iVar6,(int)func,*(FILE **)puVar3)" ( identifier , (cast_expression "(int)func" ( (type_descriptor "int" primitive_type) ) identifier) , (pointer_expression "*(FILE **)puVar3" * (cast_expression "(FILE **)puVar3" ( (type_descriptor "FILE **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) ))) ;) (expression_statement "iVar5 = js.j_jobslots;" (assignment_expression "iVar5 = js.j_jobslots" identifier = (field_expression "js.j_jobslots" identifier . field_identifier)) ;) })) (expression_statement "iVar6 = iVar6 + 1;" (assignment_expression "iVar6 = iVar6 + 1" identifier = (binary_expression "iVar6 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar6 < iVar5)" ( (binary_expression "iVar6 < iVar5" identifier < identifier) )) ;) }))) })) (labeled_statement "LAB_000687b2:\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    return 0;\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    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "undefined4 __regparm3 FUN_00068700(undefined4 param_1,int param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    \n  FUN_0010f8b0();\n}\n\n" (function_definition "undefined4 __regparm3 FUN_00068700(undefined4 param_1,int param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    \n  FUN_0010f8b0();\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_00068700(undefined4 param_1,int param_2)" identifier (parameter_list "(undefined4 param_1,int param_2)" ( (parameter_declaration "undefined4 param_1" type_identifier identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    \n  FUN_0010f8b0();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" 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 = 0x6870b;" (assignment_expression "uStack_14 = 0x6870b" 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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }" if (parenthesized_expression "(0 < DAT_001727d8)" ( (binary_expression "0 < DAT_001727d8" number_literal < identifier) )) (compound_statement "{\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }" { (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) (if_statement "if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" if (parenthesized_expression "(param_2 == -1)" ( (binary_expression "param_2 == -1" identifier == number_literal) )) (compound_statement "{\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }" { (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" identifier = number_literal) ;) (expression_statement "iVar2 = jobs;" (assignment_expression "iVar2 = jobs" identifier = identifier) ;) (expression_statement "iVar3 = DAT_001727d8;" (assignment_expression "iVar3 = DAT_001727d8" identifier = identifier) ;) (do_statement "do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);" do (compound_statement "{\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      }" { (expression_statement "iVar1 = *(int *)(iVar2 + iVar4 * 4);" (assignment_expression "iVar1 = *(int *)(iVar2 + iVar4 * 4)" identifier = (pointer_expression "*(int *)(iVar2 + iVar4 * 4)" * (cast_expression "(int *)(iVar2 + iVar4 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar2 + iVar4 * 4)" ( (binary_expression "iVar2 + iVar4 * 4" identifier + (binary_expression "iVar4 * 4" identifier * number_literal)) ))))) ;) (while_statement "while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }" while (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (compound_statement "{\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }" { (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) (expression_statement "FUN_00067e90();" (call_expression "FUN_00067e90()" identifier (argument_list "()" ( ))) ;) (if_statement "if (DAT_001727d8 <= iVar4) goto LAB_000687b2;" if (parenthesized_expression "(DAT_001727d8 <= iVar4)" ( (binary_expression "DAT_001727d8 <= iVar4" identifier <= identifier) )) (goto_statement "goto LAB_000687b2;" goto statement_identifier ;)) (expression_statement "iVar2 = jobs;" (assignment_expression "iVar2 = jobs" identifier = identifier) ;) (expression_statement "iVar3 = DAT_001727d8;" (assignment_expression "iVar3 = DAT_001727d8" identifier = identifier) ;) (expression_statement "iVar1 = *(int *)(jobs + iVar4 * 4);" (assignment_expression "iVar1 = *(int *)(jobs + iVar4 * 4)" identifier = (pointer_expression "*(int *)(jobs + iVar4 * 4)" * (cast_expression "(int *)(jobs + iVar4 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(jobs + iVar4 * 4)" ( (binary_expression "jobs + iVar4 * 4" identifier + (binary_expression "iVar4 * 4" identifier * number_literal)) ))))) ;) })) (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" identifier = (binary_expression "iVar4 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar4 < iVar3)" ( (binary_expression "iVar4 < iVar3" identifier < identifier) )) ;) }) (else_clause "else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" else (compound_statement "{\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" { (do_statement "do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);" do (compound_statement "{\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      }" { (expression_statement "iVar4 = *(int *)(jobs + iVar3 * 4);" (assignment_expression "iVar4 = *(int *)(jobs + iVar3 * 4)" identifier = (pointer_expression "*(int *)(jobs + iVar3 * 4)" * (cast_expression "(int *)(jobs + iVar3 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(jobs + iVar3 * 4)" ( (binary_expression "jobs + iVar3 * 4" identifier + (binary_expression "iVar3 * 4" identifier * number_literal)) ))))) ;) (if_statement "if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }" if (parenthesized_expression "((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc)))" ( (binary_expression "(iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))" (parenthesized_expression "(iVar4 != 0)" ( (binary_expression "iVar4 != 0" identifier != number_literal) )) && (parenthesized_expression "(param_2 == *(int *)(iVar4 + 0xc))" ( (binary_expression "param_2 == *(int *)(iVar4 + 0xc)" identifier == (pointer_expression "*(int *)(iVar4 + 0xc)" * (cast_expression "(int *)(iVar4 + 0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0xc)" ( (binary_expression "iVar4 + 0xc" identifier + number_literal) ))))) ))) )) (compound_statement "{\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }" { (expression_statement "FUN_00067e90();" (call_expression "FUN_00067e90()" identifier (argument_list "()" ( ))) ;) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" identifier = identifier) ;) })) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(iVar3 < iVar2)" ( (binary_expression "iVar3 < iVar2" identifier < identifier) )) ;) }))) })) (labeled_statement "LAB_000687b2:\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    return 0;\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    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "FUN_0010f8b0();" (call_expression "FUN_0010f8b0()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (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 ;) (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 LIT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression IDENT * LIT)) ))))) ;) (while_statement while (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression IDENT * LIT)) ))))) ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < IDENT) )) ;) }) (else_clause else (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression IDENT * LIT)) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) && (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 ( ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < IDENT) )) ;) }))) })) (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 { (return_statement return LIT ;) })) (expression_statement (call_expression IDENT (argument_list ( ))) ;) })))
(function_definition "undefined4 __regparm3 FUN_00068700(undefined4 param_1,int param_2)\n\n{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    \n  FUN_0010f8b0();\n}" (type_identifier "undefined4") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_00068700(undefined4 param_1,int param_2)" (identifier "FUN_00068700") (parameter_list "(undefined4 param_1,int param_2)" (( "(") (parameter_declaration "undefined4 param_1" (type_identifier "undefined4") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) () ")"))) (compound_statement "{\n  int iVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\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 = 0x6870b;\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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }\nLAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);\n  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return 0;\n  }\n                    \n  FUN_0010f8b0();\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 iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (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 = 0x6870b;" (assignment_expression "uStack_14 = 0x6870b" (identifier "uStack_14") (= "=") (number_literal "0x6870b")) (; ";")) (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 (0 < DAT_001727d8) {\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }" (if "if") (parenthesized_expression "(0 < DAT_001727d8)" (( "(") (binary_expression "0 < DAT_001727d8" (number_literal "0") (< "<") (identifier "DAT_001727d8")) () ")")) (compound_statement "{\n    iVar3 = 0;\n    iVar2 = DAT_001727d8;\n    if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }\n  }" ({ "{") (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" (identifier "iVar3") (= "=") (number_literal "0")) (; ";")) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" (identifier "iVar2") (= "=") (identifier "DAT_001727d8")) (; ";")) (if_statement "if (param_2 == -1) {\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }\n    else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" (if "if") (parenthesized_expression "(param_2 == -1)" (( "(") (binary_expression "param_2 == -1" (identifier "param_2") (== "==") (number_literal "-1")) () ")")) (compound_statement "{\n      iVar4 = 0;\n      iVar2 = jobs;\n      iVar3 = DAT_001727d8;\n      do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);\n    }" ({ "{") (expression_statement "iVar4 = 0;" (assignment_expression "iVar4 = 0" (identifier "iVar4") (= "=") (number_literal "0")) (; ";")) (expression_statement "iVar2 = jobs;" (assignment_expression "iVar2 = jobs" (identifier "iVar2") (= "=") (identifier "jobs")) (; ";")) (expression_statement "iVar3 = DAT_001727d8;" (assignment_expression "iVar3 = DAT_001727d8" (identifier "iVar3") (= "=") (identifier "DAT_001727d8")) (; ";")) (do_statement "do {\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      } while (iVar4 < iVar3);" (do "do") (compound_statement "{\n        iVar1 = *(int *)(iVar2 + iVar4 * 4);\n        while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }\n        iVar4 = iVar4 + 1;\n      }" ({ "{") (expression_statement "iVar1 = *(int *)(iVar2 + iVar4 * 4);" (assignment_expression "iVar1 = *(int *)(iVar2 + iVar4 * 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(iVar2 + iVar4 * 4)" (* "*") (cast_expression "(int *)(iVar2 + iVar4 * 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar2 + iVar4 * 4)" (( "(") (binary_expression "iVar2 + iVar4 * 4" (identifier "iVar2") (+ "+") (binary_expression "iVar4 * 4" (identifier "iVar4") (* "*") (number_literal "4"))) () ")"))))) (; ";")) (while_statement "while (iVar1 != 0) {\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }" (while "while") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n          iVar4 = iVar4 + 1;\n          FUN_00067e90();\n          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;\n          iVar2 = jobs;\n          iVar3 = DAT_001727d8;\n          iVar1 = *(int *)(jobs + iVar4 * 4);\n        }" ({ "{") (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" (identifier "iVar4") (= "=") (binary_expression "iVar4 + 1" (identifier "iVar4") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "FUN_00067e90();" (call_expression "FUN_00067e90()" (identifier "FUN_00067e90") (argument_list "()" (( "(") () ")"))) (; ";")) (if_statement "if (DAT_001727d8 <= iVar4) goto LAB_000687b2;" (if "if") (parenthesized_expression "(DAT_001727d8 <= iVar4)" (( "(") (binary_expression "DAT_001727d8 <= iVar4" (identifier "DAT_001727d8") (<= "<=") (identifier "iVar4")) () ")")) (goto_statement "goto LAB_000687b2;" (goto "goto") (statement_identifier "LAB_000687b2") (; ";"))) (expression_statement "iVar2 = jobs;" (assignment_expression "iVar2 = jobs" (identifier "iVar2") (= "=") (identifier "jobs")) (; ";")) (expression_statement "iVar3 = DAT_001727d8;" (assignment_expression "iVar3 = DAT_001727d8" (identifier "iVar3") (= "=") (identifier "DAT_001727d8")) (; ";")) (expression_statement "iVar1 = *(int *)(jobs + iVar4 * 4);" (assignment_expression "iVar1 = *(int *)(jobs + iVar4 * 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(jobs + iVar4 * 4)" (* "*") (cast_expression "(int *)(jobs + iVar4 * 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(jobs + iVar4 * 4)" (( "(") (binary_expression "jobs + iVar4 * 4" (identifier "jobs") (+ "+") (binary_expression "iVar4 * 4" (identifier "iVar4") (* "*") (number_literal "4"))) () ")"))))) (; ";")) (} "}"))) (expression_statement "iVar4 = iVar4 + 1;" (assignment_expression "iVar4 = iVar4 + 1" (identifier "iVar4") (= "=") (binary_expression "iVar4 + 1" (identifier "iVar4") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar4 < iVar3)" (( "(") (binary_expression "iVar4 < iVar3" (identifier "iVar4") (< "<") (identifier "iVar3")) () ")")) (; ";")) (} "}")) (else_clause "else {\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" (else "else") (compound_statement "{\n      do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);\n    }" ({ "{") (do_statement "do {\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      } while (iVar3 < iVar2);" (do "do") (compound_statement "{\n        iVar4 = *(int *)(jobs + iVar3 * 4);\n        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }\n        iVar3 = iVar3 + 1;\n      }" ({ "{") (expression_statement "iVar4 = *(int *)(jobs + iVar3 * 4);" (assignment_expression "iVar4 = *(int *)(jobs + iVar3 * 4)" (identifier "iVar4") (= "=") (pointer_expression "*(int *)(jobs + iVar3 * 4)" (* "*") (cast_expression "(int *)(jobs + iVar3 * 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(jobs + iVar3 * 4)" (( "(") (binary_expression "jobs + iVar3 * 4" (identifier "jobs") (+ "+") (binary_expression "iVar3 * 4" (identifier "iVar3") (* "*") (number_literal "4"))) () ")"))))) (; ";")) (if_statement "if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }" (if "if") (parenthesized_expression "((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc)))" (( "(") (binary_expression "(iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))" (parenthesized_expression "(iVar4 != 0)" (( "(") (binary_expression "iVar4 != 0" (identifier "iVar4") (!= "!=") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "(param_2 == *(int *)(iVar4 + 0xc))" (( "(") (binary_expression "param_2 == *(int *)(iVar4 + 0xc)" (identifier "param_2") (== "==") (pointer_expression "*(int *)(iVar4 + 0xc)" (* "*") (cast_expression "(int *)(iVar4 + 0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0xc)" (( "(") (binary_expression "iVar4 + 0xc" (identifier "iVar4") (+ "+") (number_literal "0xc")) () ")"))))) () ")"))) () ")")) (compound_statement "{\n          FUN_00067e90();\n          iVar2 = DAT_001727d8;\n        }" ({ "{") (expression_statement "FUN_00067e90();" (call_expression "FUN_00067e90()" (identifier "FUN_00067e90") (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "iVar2 = DAT_001727d8;" (assignment_expression "iVar2 = DAT_001727d8" (identifier "iVar2") (= "=") (identifier "DAT_001727d8")) (; ";")) (} "}"))) (expression_statement "iVar3 = iVar3 + 1;" (assignment_expression "iVar3 = iVar3 + 1" (identifier "iVar3") (= "=") (binary_expression "iVar3 + 1" (identifier "iVar3") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar3 < iVar2)" (( "(") (binary_expression "iVar3 < iVar2" (identifier "iVar3") (< "<") (identifier "iVar2")) () ")")) (; ";")) (} "}")))) (} "}"))) (labeled_statement "LAB_000687b2:\n  sigprocmask(2,&local_a0,(sigset_t *)0x0);" (statement_identifier "LAB_000687b2") (: ":") (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    return 0;\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    return 0;\n  }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "FUN_0010f8b0();" (call_expression "FUN_0010f8b0()" (identifier "FUN_0010f8b0") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))

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

int __regparm3 function_1(type_1 *func,int var_5,int arg2)

{
  int var_11;
  type_2 *var_6;
  type_3 *puVar3;
  type_2 **ppJVar4;
  int var_10;
  int var_7;
  int var_9;
  int var_1;
  type_4 set;
  type_4 oset;
  
  var_11 = *(int *)(var_1 + 0x14);
  var_2((type_4 *)&set);
  var_3((type_4 *)&set,0x11);
  var_2((type_4 *)&oset);
  var_4(0,(type_4 *)&set,(type_4 *)&oset);
  puVar3 = PTR_stdout_00171f70;
  if (0 < js.j_jobslots) {
    var_7 = 0;
    var_10 = js.j_jobslots;
    if (var_5 == -1) {
      var_7 = 0;
      ppJVar4 = jobs;
      do {
        var_6 = ppJVar4[var_7];
        while (var_6 != (type_2 *)0x0) {
          var_9 = var_7 + 1;
          var_8(var_7,(int)func,*(type_5 **)puVar3);
          if (js.j_jobslots <= var_9) goto LAB_000687b2;
          ppJVar4 = jobs;
          var_10 = js.j_jobslots;
          var_7 = var_9;
          var_6 = jobs[var_9];
        }
        var_7 = var_7 + 1;
      } while (var_7 < var_10);
    }
    else {
      do {
        if ((jobs[var_7] != (type_2 *)0x0) && (var_5 == jobs[var_7]->state)) {
          var_8(var_7,(int)func,*(type_5 **)puVar3);
          var_10 = js.j_jobslots;
        }
        var_7 = var_7 + 1;
      } while (var_7 < var_10);
    }
  }
LAB_000687b2:
  var_4(2,(type_4 *)&oset,(type_4 *)0x0);
  if (var_11 == *(int *)(var_1 + 0x14)) {
    return 0;
  }
                    /* WARNING: Subroutine does not return */
  var_12();
}


(translation_unit (function_definition type: (type_identifier) (ERROR (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (identifier)) (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: (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: (number_literal) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (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))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (do_statement body: (compound_statement (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: (binary_expression left: (identifier) right: (number_literal)))))))) (while_statement condition: (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)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (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: (binary_expression left: (identifier) right: (number_literal)))))))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))))) alternative: (else_clause (compound_statement (do_statement body: (compound_statement (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: (binary_expression left: (identifier) right: (number_literal)))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (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))) (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))))))))) (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 (return_statement (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list))))))

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

undefined4 __regparm3 MASKED(undefined4 param_1,int param_2)

{
  int iVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  int in_GS_OFFSET;
  sigset_t local_120;
  sigset_t local_a0;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x6870b;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  sigemptyset(&local_120);
  sigaddset(&local_120,0x11);
  sigemptyset(&local_a0);
  sigprocmask(0,&local_120,&local_a0);
  if (0 < DAT_001727d8) {
    iVar3 = 0;
    iVar2 = DAT_001727d8;
    if (param_2 == -1) {
      iVar4 = 0;
      iVar2 = jobs;
      iVar3 = DAT_001727d8;
      do {
        iVar1 = *(int *)(iVar2 + iVar4 * 4);
        while (iVar1 != 0) {
          iVar4 = iVar4 + 1;
          FUN_00067e90();
          if (DAT_001727d8 <= iVar4) goto LAB_000687b2;
          iVar2 = jobs;
          iVar3 = DAT_001727d8;
          iVar1 = *(int *)(jobs + iVar4 * 4);
        }
        iVar4 = iVar4 + 1;
      } while (iVar4 < iVar3);
    }
    else {
      do {
        iVar4 = *(int *)(jobs + iVar3 * 4);
        if ((iVar4 != 0) && (param_2 == *(int *)(iVar4 + 0xc))) {
          FUN_00067e90();
          iVar2 = DAT_001727d8;
        }
        iVar3 = iVar3 + 1;
      } while (iVar3 < iVar2);
    }
  }
LAB_000687b2:
  sigprocmask(2,&local_a0,(sigset_t *)0x0);
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return 0;
  }
                    /* WARNING: Subroutine does not return */
  FUN_0010f8b0();
}

