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

void png_write_iTXt(png_structrp png_ptr,int compression,png_const_charp key,png_const_charp lang,
                   png_const_charp lang_key,png_const_charp text)

{
  int iVar1;
  bool bVar2;
  png_uint_32 pVar3;
  size_t length;
  size_t sVar4;
  int iVar5;
  png_byte *data;
  compression_state *comp_00;
  uint length_00;
  png_compression_bufferp ppVar6;
  int in_GS_OFFSET;
  png_uint_32 in_stack_fffffb54;
  uint local_4a8;
  png_const_bytep local_4a4;
  png_const_bytep local_4a0;
  uint local_498;
  compression_state comp;
  png_byte buf [8];
  png_byte new_key [82];
  
  local_4a4 = (png_const_bytep)lang;
  local_4a0 = (png_const_bytep)lang_key;
  iVar1 = *(int *)(in_GS_OFFSET + 0x14);
  pVar3 = png_check_keyword(png_ptr,key,new_key);
  if (pVar3 == 0) {
                    /* WARNING: Subroutine does not return */
    png_error(png_ptr,"iTXt: invalid keyword");
  }
  if (compression == 0) {
LAB_0003c58f:
    bVar2 = true;
    new_key[pVar3 + 1] = '\x01';
  }
  else {
    if (compression < 1) {
      if (compression != -1) {
LAB_0003c9ae:
                    /* WARNING: Subroutine does not return */
        png_error(png_ptr,"iTXt: invalid compression");
      }
    }
    else if (compression != 1) {
      if (compression != 2) goto LAB_0003c9ae;
      goto LAB_0003c58f;
    }
    bVar2 = false;
    new_key[pVar3 + 1] = '\0';
  }
  new_key[pVar3 + 2] = '\0';
  length = pVar3 + 3;
  if (lang == (png_const_charp)0x0) {
    local_4a4 = "";
    local_4a8 = 1;
  }
  else {
    sVar4 = strlen(lang);
    local_4a8 = sVar4 + 1;
  }
  if (lang_key == (png_const_charp)0x0) {
    local_4a0 = "";
    local_498 = 1;
  }
  else {
    sVar4 = strlen(lang_key);
    local_498 = sVar4 + 1;
  }
  if (text == (png_const_charp)0x0) {
    comp.input_len = 0;
    text = "";
  }
  else {
    comp.input_len = strlen(text);
  }
  comp_00 = (compression_state *)0x7fffffff;
  if ((local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length))) {
    comp_00 = (compression_state *)(local_4a8 + length + local_498);
  }
  comp.output_len = 0;
  comp.input = (png_const_bytep)text;
  if (bVar2) {
    iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);
    if ((iVar5 != 0) ||
       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)
       ) {
                    /* WARNING: Subroutine does not return */
      png_error(png_ptr,(png_ptr->zstream).msg);
    }
    if (png_ptr == (png_structrp)0x0) {
      png_write_chunk_data((png_structrp)0x0,new_key,length);
      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);
      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);
    }
    else {
      png_ptr->io_state = 0x22;
      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));
      png_save_uint_32(buf + 4,0x69545874);
      png_write_data(png_ptr,buf,8);
      png_ptr->chunk_name = 0x69545874;
      png_reset_crc(png_ptr);
      png_calculate_crc(png_ptr,buf + 4,4);
      png_ptr->io_state = 0x42;
      png_write_chunk_data(png_ptr,new_key,length);
      png_write_chunk_data(png_ptr,local_4a4,local_4a8);
      png_write_chunk_data(png_ptr,local_4a0,local_498);
    }
    pVar3 = comp.output_len;
    if (comp.output_len < 0x400) {
      data = comp.output;
LAB_0003c8f2:
      png_write_chunk_data(png_ptr,data,pVar3);
    }
    else {
      ppVar6 = png_ptr->zbuffer_list;
      data = comp.output;
      length_00 = 0x400;
      while( true ) {
        png_write_chunk_data(png_ptr,data,length_00);
        pVar3 = pVar3 - length_00;
        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;
        length_00 = png_ptr->zbuffer_size;
        data = ppVar6->output;
        if (pVar3 < length_00) goto LAB_0003c8f2;
        ppVar6 = ppVar6->next;
      }
      if (pVar3 != 0) {
                    /* WARNING: Subroutine does not return */
        png_error(png_ptr,"error writing ancillary chunked compressed data");
      }
    }
  }
  else {
    if (0x7fffffffU - (int)comp_00 < comp.input_len) {
                    /* WARNING: Subroutine does not return */
      png_error(png_ptr,"iTXt: uncompressed text too long");
    }
    comp.output_len = comp.input_len;
    if (png_ptr == (png_structrp)0x0) {
      png_write_chunk_data((png_structrp)0x0,new_key,length);
      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);
      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);
    }
    else {
      png_ptr->io_state = 0x22;
      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));
      png_save_uint_32(buf + 4,0x69545874);
      png_write_data(png_ptr,buf,8);
      png_ptr->chunk_name = 0x69545874;
      png_reset_crc(png_ptr);
      png_calculate_crc(png_ptr,buf + 4,4);
      png_ptr->io_state = 0x42;
      png_write_chunk_data(png_ptr,new_key,length);
      png_write_chunk_data(png_ptr,local_4a4,local_4a8);
      png_write_chunk_data(png_ptr,local_4a0,local_498);
    }
    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);
  }
  png_write_chunk_end(png_ptr);
  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    __stack_chk_fail_local();
  }
  return;
}



/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Removing unreachable block (ram,0x0003c8a0) */
/* WARNING: Removing unreachable block (ram,0x0003c8b8) */
/* WARNING: Removing unreachable block (ram,0x0003c8d6) */
/* WARNING: Removing unreachable block (ram,0x0003c9e0) */
/* WARNING: Removing unreachable block (ram,0x0003c9ea) */
/* WARNING: Removing unreachable block (ram,0x0003c8de) */
/* WARNING: Removing unreachable block (ram,0x0003c8f0) */
/* WARNING: Removing unreachable block (ram,0x0003c8eb) */

void FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,
                 char *param_6)

{
  bool bVar1;
  int iVar2;
  size_t sVar3;
  uint uVar4;
  int iVar5;
  undefined4 extraout_ECX;
  int iVar6;
  int in_GS_OFFSET;
  uint local_4a8;
  char *local_4a4;
  char *local_4a0;
  uint local_498;
  undefined1 local_47c [1026];
  undefined1 local_7a [4];
  undefined1 local_76 [4];
  undefined1 local_72;
  undefined1 auStack_71 [81];
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x3c509;
  local_4a4 = param_4;
  local_4a0 = param_5;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  iVar2 = FUN_00035490(param_1,param_3,&local_72);
  if (iVar2 == 0) {
                    /* WARNING: Subroutine does not return */
    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);
  }
  if (param_2 == 0) {
LAB_0003c58f:
    bVar1 = true;
    auStack_71[iVar2] = 1;
  }
  else {
    if (param_2 < 1) {
      if (param_2 != -1) {
LAB_0003c9ae:
                    /* WARNING: Subroutine does not return */
        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);
      }
    }
    else if (param_2 != 1) {
      if (param_2 != 2) goto LAB_0003c9ae;
      goto LAB_0003c58f;
    }
    bVar1 = false;
    auStack_71[iVar2] = 0;
  }
  auStack_71[iVar2 + 1] = 0;
  iVar2 = iVar2 + 3;
  if (param_4 == (char *)0x0) {
    local_4a4 = "";
    local_4a8 = 1;
  }
  else {
    sVar3 = strlen(param_4);
    local_4a8 = sVar3 + 1;
  }
  if (param_5 == (char *)0x0) {
    local_4a0 = "";
    local_498 = 1;
  }
  else {
    sVar3 = strlen(param_5);
    local_498 = sVar3 + 1;
  }
  if (param_6 == (char *)0x0) {
    uVar4 = 0;
    param_6 = "";
  }
  else {
    uVar4 = strlen(param_6);
  }
  iVar6 = 0x7fffffff;
  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {
    iVar6 = local_4a8 + iVar2 + local_498;
  }
  if (bVar1) {
    iVar5 = FUN_0003a060();
    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {
                    /* WARNING: Subroutine does not return */
      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));
    }
    if (param_1 == 0) {
      png_write_chunk_data(0,&local_72,iVar2);
      png_write_chunk_data(0,local_4a4,local_4a8);
      png_write_chunk_data(0,local_4a0,local_498);
    }
    else {
      *(undefined4 *)(param_1 + 0x32c) = 0x22;
      png_save_uint_32(local_7a,iVar6);
      png_save_uint_32(local_76,0x69545874);
      FUN_000360c0(param_1,local_7a,8);
      *(undefined4 *)(param_1 + 0x178) = 0x69545874;
      FUN_00014f90(param_1);
      FUN_00014fc0(param_1,local_76,4);
      *(undefined4 *)(param_1 + 0x32c) = 0x42;
      png_write_chunk_data(param_1,&local_72,iVar2);
      png_write_chunk_data(param_1,local_4a4,local_4a8);
      png_write_chunk_data(param_1,local_4a0,local_498);
    }
    png_write_chunk_data(param_1,local_47c,0);
  }
  else {
    if (0x7fffffffU - iVar6 < uVar4) {
                    /* WARNING: Subroutine does not return */
      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);
    }
    if (param_1 == 0) {
      png_write_chunk_data(0,&local_72,iVar2);
      png_write_chunk_data(0,local_4a4,local_4a8);
      png_write_chunk_data(0,local_4a0,local_498);
    }
    else {
      *(undefined4 *)(param_1 + 0x32c) = 0x22;
      png_save_uint_32(local_7a,uVar4 + iVar6);
      png_save_uint_32(local_76,0x69545874);
      FUN_000360c0(param_1,local_7a,8);
      *(undefined4 *)(param_1 + 0x178) = 0x69545874;
      FUN_00014f90(param_1);
      FUN_00014fc0(param_1,local_76,4);
      *(undefined4 *)(param_1 + 0x32c) = 0x42;
      png_write_chunk_data(param_1,&local_72,iVar2);
      png_write_chunk_data(param_1,local_4a4,local_4a8);
      png_write_chunk_data(param_1,local_4a0,local_498);
    }
    png_write_chunk_data(param_1,param_6,uVar4);
  }
  png_write_chunk_end(param_1);
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_0003f340();
  }
  return;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00014970
ADD EBX,0x17877
SUB ESP,0x4a0
MOV EAX,dword ptr [ESP + 0x4c0]
MOV ESI,dword ptr [ESP + 0x4b4]
MOV EBP,dword ptr [ESP + 0x4b8]
MOV EDI,dword ptr [ESP + 0x4c8]
MOV dword ptr [ESP + 0xc],EAX
MOV EAX,dword ptr [ESP + 0x4c4]
MOV dword ptr [ESP + 0x10],EAX
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0x490],EAX
XOR EAX,EAX
LEA EAX,[ESP + 0x43e]
MOV dword ptr [ESP + 0x1c],EAX
PUSH EAX
PUSH dword ptr [ESP + 0x4c0]
PUSH ESI
CALL 0x00035490
ADD ESP,0x10
TEST EAX,EAX
JZ 0x0003c9c2
TEST EBP,EBP
JZ 0x0003c58f
JLE 0x0003c738
CMP EBP,0x1
JZ 0x0003c741
CMP EBP,0x2
JNZ 0x0003c9ae
ADD EAX,0x1
MOV dword ptr [ESP + 0x1c],0x1
MOV byte ptr [ESP + EAX*0x1 + 0x43a],0x1
MOV byte ptr [ESP + EAX*0x1 + 0x43b],0x0
ADD EAX,0x2
MOV dword ptr [ESP + 0x10],EAX
MOV EAX,dword ptr [ESP + 0x8]
TEST EAX,EAX
JZ 0x0003c930
SUB ESP,0xc
PUSH EAX
CALL 0x00014530
ADD ESP,0x10
ADD EAX,0x1
MOV dword ptr [ESP + 0x4],EAX
MOV EAX,dword ptr [ESP + 0xc]
TEST EAX,EAX
JZ 0x0003c918
SUB ESP,0xc
PUSH EAX
CALL 0x00014530
ADD ESP,0x10
ADD EAX,0x1
MOV dword ptr [ESP + 0x14],EAX
TEST EDI,EDI
JZ 0x0003c908
SUB ESP,0xc
PUSH EDI
CALL 0x00014530
ADD ESP,0x10
MOV ECX,dword ptr [ESP + 0x10]
MOV EDX,0x7fffffff
MOV EBP,0x7fffffff
SUB EDX,ECX
CMP EDX,dword ptr [ESP + 0x4]
JNC 0x0003c760
MOV EDX,dword ptr [ESP + 0x1c]
MOV dword ptr [ESP + 0x24],EDI
MOV dword ptr [ESP + 0x28],EAX
MOV dword ptr [ESP + 0x2c],0x0
TEST EDX,EDX
JNZ 0x0003c7c0
MOV EDX,0x7fffffff
SUB EDX,EBP
CMP EDX,EAX
JC 0x0003c9d1
MOV dword ptr [ESP + 0x2c],EAX
TEST ESI,ESI
JZ 0x0003c780
MOV dword ptr [ESI + 0x32c],0x22
SUB ESP,0x8
ADD EAX,EBP
PUSH EAX
LEA EAX,[ESP + 0x43e]
PUSH EAX
MOV dword ptr [ESP + 0x2c],EAX
CALL 0x00014500
POP EBP
POP EAX
PUSH 0x69545874
LEA EBP,[ESP + 0x442]
PUSH EBP
CALL 0x00014500
ADD ESP,0xc
PUSH 0x8
MOV EAX,dword ptr [ESP + 0x24]
PUSH EAX
PUSH ESI
CALL 0x000360c0
MOV dword ptr [ESI + 0x178],0x69545874
MOV dword ptr [ESP],ESI
CALL 0x00014f90
ADD ESP,0xc
PUSH 0x4
PUSH EBP
PUSH ESI
CALL 0x00014fc0
ADD ESP,0xc
MOV dword ptr [ESI + 0x32c],0x42
PUSH dword ptr [ESP + 0x14]
PUSH dword ptr [ESP + 0x20]
PUSH ESI
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x8]
PUSH dword ptr [ESP + 0x10]
PUSH ESI
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x18]
PUSH dword ptr [ESP + 0x14]
PUSH ESI
CALL 0x000140d0
ADD ESP,0x10
SUB ESP,0x4
PUSH dword ptr [ESP + 0x30]
PUSH EDI
PUSH ESI
CALL 0x000140d0
ADD ESP,0x10
SUB ESP,0xc
PUSH ESI
CALL 0x00014470
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0x48c]
XOR EAX,dword ptr GS:[0x14]
JNZ 0x0003c9bd
ADD ESP,0x49c
POP EBX
POP ESI
POP EDI
POP EBP
RET
CMP EBP,-0x1
JNZ 0x0003c9ae
ADD EAX,0x1
MOV dword ptr [ESP + 0x1c],0x0
MOV byte ptr [ESP + EAX*0x1 + 0x43a],0x0
JMP 0x0003c5a2
MOV EDX,dword ptr [ESP + 0x4]
ADD EDX,ECX
MOV ECX,EBP
SUB ECX,EDX
CMP ECX,dword ptr [ESP + 0x14]
JC 0x0003c61d
MOV ECX,dword ptr [ESP + 0x14]
LEA EBP,[EDX + ECX*0x1]
JMP 0x0003c61d
SUB ESP,0x4
PUSH dword ptr [ESP + 0x14]
PUSH dword ptr [ESP + 0x20]
PUSH 0x0
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x8]
PUSH dword ptr [ESP + 0x10]
PUSH 0x0
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x18]
PUSH dword ptr [ESP + 0x14]
PUSH 0x0
CALL 0x000140d0
ADD ESP,0x10
JMP 0x0003c6f7
MOV ECX,EAX
MOV EDX,0x69545874
MOV EAX,ESI
CALL 0x0003a060
TEST EAX,EAX
JNZ 0x0003c960
LEA EDX,[ESP + 0x24]
MOV ECX,EBP
MOV EAX,ESI
CALL 0x0003a340
TEST EAX,EAX
JNZ 0x0003c960
TEST ESI,ESI
JZ 0x0003c970
ADD EBP,dword ptr [ESP + 0x2c]
SUB ESP,0x8
MOV dword ptr [ESI + 0x32c],0x22
PUSH EBP
LEA EBP,[ESP + 0x43e]
PUSH EBP
CALL 0x00014500
POP EAX
POP EDX
PUSH 0x69545874
LEA EDI,[ESP + 0x442]
PUSH EDI
CALL 0x00014500
ADD ESP,0xc
PUSH 0x8
PUSH EBP
PUSH ESI
CALL 0x000360c0
MOV dword ptr [ESI + 0x178],0x69545874
MOV dword ptr [ESP],ESI
CALL 0x00014f90
ADD ESP,0xc
PUSH 0x4
PUSH EDI
PUSH ESI
CALL 0x00014fc0
ADD ESP,0xc
MOV dword ptr [ESI + 0x32c],0x42
PUSH dword ptr [ESP + 0x14]
PUSH dword ptr [ESP + 0x20]
PUSH ESI
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x8]
PUSH dword ptr [ESP + 0x10]
PUSH ESI
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x18]
PUSH dword ptr [ESP + 0x14]
PUSH ESI
CALL 0x000140d0
ADD ESP,0x10
MOV EDI,dword ptr [ESP + 0x2c]
CMP EDI,0x3ff
JBE 0x0003c950
MOV EAX,dword ptr [ESI + 0x118]
MOV ECX,ESI
LEA EDX,[ESP + 0x30]
MOV EBP,0x400
MOV ESI,EAX
MOV EAX,ECX
LEA ESI,[ESI]
SUB ESP,0x4
PUSH EBP
PUSH EDX
PUSH EAX
MOV dword ptr [ESP + 0x14],EAX
CALL 0x000140d0
ADD ESP,0x10
SUB EDI,EBP
MOV EAX,dword ptr [ESP + 0x4]
JZ 0x0003c9e0
TEST ESI,ESI
JZ 0x0003c9e0
MOV EBP,dword ptr [EAX + 0x11c]
LEA EDX,[ESI + 0x4]
CMP EDI,EBP
JC 0x0003c8f0
MOV ESI,dword ptr [ESI]
JMP 0x0003c8b8
MOV ESI,EAX
SUB ESP,0x4
PUSH EDI
PUSH EDX
PUSH ESI
CALL 0x000140d0
ADD ESP,0x10
JMP 0x0003c708
XOR EAX,EAX
LEA EDI,[EBX + 0xfffec865]
JMP 0x0003c603
LEA EAX,[EBX + 0xfffec865]
MOV dword ptr [ESP + 0x14],0x1
MOV dword ptr [ESP + 0xc],EAX
JMP 0x0003c5ef
LEA EAX,[EBX + 0xfffec865]
MOV dword ptr [ESP + 0x4],0x1
MOV dword ptr [ESP + 0x8],EAX
JMP 0x0003c5d0
LEA EDX,[ESP + 0x30]
JMP 0x0003c8f2
SUB ESP,0x8
PUSH dword ptr [ESI + 0xf8]
PUSH ESI
CALL 0x00014460
SUB ESP,0x4
PUSH dword ptr [ESP + 0x14]
PUSH dword ptr [ESP + 0x20]
PUSH 0x0
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x8]
PUSH dword ptr [ESP + 0x10]
PUSH 0x0
CALL 0x000140d0
ADD ESP,0xc
PUSH dword ptr [ESP + 0x18]
PUSH dword ptr [ESP + 0x14]
PUSH 0x0
CALL 0x000140d0
ADD ESP,0x10
JMP 0x0003c890
LEA EAX,[EBX + 0xffff05c8]
PUSH ECX
PUSH ECX
PUSH EAX
PUSH ESI
CALL 0x00014460
CALL 0x0003f340
LEA EAX,[EBX + 0xffff05b2]
PUSH EDI
PUSH EDI
PUSH EAX
PUSH ESI
CALL 0x00014460
PUSH EAX
PUSH EAX
LEA EAX,[EBX + 0xffff09d8]
PUSH EAX
PUSH ESI
CALL 0x00014460
MOV ESI,EAX
TEST EDI,EDI
JZ 0x0003c708
LEA EAX,[EBX + 0xffff07dc]
PUSH ECX
PUSH ECX
PUSH EAX
PUSH ESI
CALL 0x00014460
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Removing unreachable block (ram,0x0003c8a0) */\n/* WARNING: Removing unreachable block (ram,0x0003c8b8) */\n/* WARNING: Removing unreachable block (ram,0x0003c8d6) */\n/* WARNING: Removing unreachable block (ram,0x0003c9e0) */\n/* WARNING: Removing unreachable block (ram,0x0003c9ea) */\n/* WARNING: Removing unreachable block (ram,0x0003c8de) */\n/* WARNING: Removing unreachable block (ram,0x0003c8f0) */\n/* WARNING: Removing unreachable block (ram,0x0003c8eb) */\n\nvoid FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)\n\n{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0003f340();\n  }\n  return;\n}\n\n" comment comment comment comment comment comment comment comment comment (function_definition "void FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)\n\n{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0003f340();\n  }\n  return;\n}" primitive_type (function_declarator "FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)" identifier (parameter_list "(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "char *param_4" primitive_type (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "char *param_5" primitive_type (pointer_declarator "*param_5" * identifier)) , (parameter_declaration "char *param_6" primitive_type (pointer_declarator "*param_6" * identifier)) ))) (compound_statement "{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0003f340();\n  }\n  return;\n}" { (declaration "bool bVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "size_t sVar3;" primitive_type identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "undefined4 extraout_ECX;" type_identifier identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "uint local_4a8;" type_identifier identifier ;) (declaration "char *local_4a4;" primitive_type (pointer_declarator "*local_4a4" * identifier) ;) (declaration "char *local_4a0;" primitive_type (pointer_declarator "*local_4a0" * identifier) ;) (declaration "uint local_498;" type_identifier identifier ;) (declaration "undefined1 local_47c [1026];" type_identifier (array_declarator "local_47c [1026]" identifier [ number_literal ]) ;) (declaration "undefined1 local_7a [4];" type_identifier (array_declarator "local_7a [4]" identifier [ number_literal ]) ;) (declaration "undefined1 local_76 [4];" type_identifier (array_declarator "local_76 [4]" identifier [ number_literal ]) ;) (declaration "undefined1 local_72;" type_identifier identifier ;) (declaration "undefined1 auStack_71 [81];" type_identifier (array_declarator "auStack_71 [81]" identifier [ number_literal ]) ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x3c509;" (assignment_expression "uStack_14 = 0x3c509" identifier = number_literal) ;) (expression_statement "local_4a4 = param_4;" (assignment_expression "local_4a4 = param_4" identifier = identifier) ;) (expression_statement "local_4a0 = param_5;" (assignment_expression "local_4a0 = param_5" identifier = identifier) ;) (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 "iVar2 = FUN_00035490(param_1,param_3,&local_72);" (assignment_expression "iVar2 = FUN_00035490(param_1,param_3,&local_72)" identifier = (call_expression "FUN_00035490(param_1,param_3,&local_72)" identifier (argument_list "(param_1,param_3,&local_72)" ( identifier , identifier , (pointer_expression "&local_72" & identifier) )))) ;) (if_statement "if (iVar2 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }" { comment (expression_statement "png_error(param_1,"iTXt: invalid keyword",param_6,param_6);" (call_expression "png_error(param_1,"iTXt: invalid keyword",param_6,param_6)" identifier (argument_list "(param_1,"iTXt: invalid keyword",param_6,param_6)" ( identifier , (string_literal ""iTXt: invalid keyword"" " string_content ") , identifier , identifier ))) ;) })) (if_statement "if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (compound_statement "{\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }" { (labeled_statement "LAB_0003c58f:\n    bVar1 = true;" statement_identifier : (expression_statement "bVar1 = true;" (assignment_expression "bVar1 = true" identifier = true) ;)) (expression_statement "auStack_71[iVar2] = 1;" (assignment_expression "auStack_71[iVar2] = 1" (subscript_expression "auStack_71[iVar2]" identifier [ identifier ]) = number_literal) ;) }) (else_clause "else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" else (compound_statement "{\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" { (if_statement "if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" if (parenthesized_expression "(param_2 < 1)" ( (binary_expression "param_2 < 1" identifier < number_literal) )) (compound_statement "{\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }" { (if_statement "if (param_2 != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }" if (parenthesized_expression "(param_2 != -1)" ( (binary_expression "param_2 != -1" identifier != number_literal) )) (compound_statement "{\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }" { (labeled_statement "LAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);" statement_identifier : comment (expression_statement "png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);" (call_expression "png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX)" identifier (argument_list "(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX)" ( identifier , (string_literal ""iTXt: invalid compression"" " string_content ") , identifier , identifier ))) ;)) })) }) (else_clause "else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" else (if_statement "if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" if (parenthesized_expression "(param_2 != 1)" ( (binary_expression "param_2 != 1" identifier != number_literal) )) (compound_statement "{\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" { (if_statement "if (param_2 != 2) goto LAB_0003c9ae;" if (parenthesized_expression "(param_2 != 2)" ( (binary_expression "param_2 != 2" identifier != number_literal) )) (goto_statement "goto LAB_0003c9ae;" goto statement_identifier ;)) (goto_statement "goto LAB_0003c58f;" goto statement_identifier ;) })))) (expression_statement "bVar1 = false;" (assignment_expression "bVar1 = false" identifier = false) ;) (expression_statement "auStack_71[iVar2] = 0;" (assignment_expression "auStack_71[iVar2] = 0" (subscript_expression "auStack_71[iVar2]" identifier [ identifier ]) = number_literal) ;) }))) (expression_statement "auStack_71[iVar2 + 1] = 0;" (assignment_expression "auStack_71[iVar2 + 1] = 0" (subscript_expression "auStack_71[iVar2 + 1]" identifier [ (binary_expression "iVar2 + 1" identifier + number_literal) ]) = number_literal) ;) (expression_statement "iVar2 = iVar2 + 3;" (assignment_expression "iVar2 = iVar2 + 3" identifier = (binary_expression "iVar2 + 3" identifier + number_literal)) ;) (if_statement "if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" if (parenthesized_expression "(param_4 == (char *)0x0)" ( (binary_expression "param_4 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    local_4a4 = "";\n    local_4a8 = 1;\n  }" { (expression_statement "local_4a4 = "";" (assignment_expression "local_4a4 = """ identifier = (string_literal """" " ")) ;) (expression_statement "local_4a8 = 1;" (assignment_expression "local_4a8 = 1" identifier = number_literal) ;) }) (else_clause "else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" else (compound_statement "{\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" { (expression_statement "sVar3 = strlen(param_4);" (assignment_expression "sVar3 = strlen(param_4)" identifier = (call_expression "strlen(param_4)" identifier (argument_list "(param_4)" ( identifier )))) ;) (expression_statement "local_4a8 = sVar3 + 1;" (assignment_expression "local_4a8 = sVar3 + 1" identifier = (binary_expression "sVar3 + 1" identifier + number_literal)) ;) }))) (if_statement "if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" if (parenthesized_expression "(param_5 == (char *)0x0)" ( (binary_expression "param_5 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    local_4a0 = "";\n    local_498 = 1;\n  }" { (expression_statement "local_4a0 = "";" (assignment_expression "local_4a0 = """ identifier = (string_literal """" " ")) ;) (expression_statement "local_498 = 1;" (assignment_expression "local_498 = 1" identifier = number_literal) ;) }) (else_clause "else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" else (compound_statement "{\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" { (expression_statement "sVar3 = strlen(param_5);" (assignment_expression "sVar3 = strlen(param_5)" identifier = (call_expression "strlen(param_5)" identifier (argument_list "(param_5)" ( identifier )))) ;) (expression_statement "local_498 = sVar3 + 1;" (assignment_expression "local_498 = sVar3 + 1" identifier = (binary_expression "sVar3 + 1" identifier + number_literal)) ;) }))) (if_statement "if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }" if (parenthesized_expression "(param_6 == (char *)0x0)" ( (binary_expression "param_6 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar4 = 0;\n    param_6 = "";\n  }" { (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (expression_statement "param_6 = "";" (assignment_expression "param_6 = """ identifier = (string_literal """" " ")) ;) }) (else_clause "else {\n    uVar4 = strlen(param_6);\n  }" else (compound_statement "{\n    uVar4 = strlen(param_6);\n  }" { (expression_statement "uVar4 = strlen(param_6);" (assignment_expression "uVar4 = strlen(param_6)" identifier = (call_expression "strlen(param_6)" identifier (argument_list "(param_6)" ( identifier )))) ;) }))) (expression_statement "iVar6 = 0x7fffffff;" (assignment_expression "iVar6 = 0x7fffffff" identifier = number_literal) ;) (if_statement "if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }" if (parenthesized_expression "((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2)))" ( (binary_expression "(local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))" (parenthesized_expression "(local_4a8 <= 0x7fffffffU - iVar2)" ( (binary_expression "local_4a8 <= 0x7fffffffU - iVar2" identifier <= (binary_expression "0x7fffffffU - iVar2" number_literal - identifier)) )) && (parenthesized_expression "(local_498 <= 0x7fffffff - (local_4a8 + iVar2))" ( (binary_expression "local_498 <= 0x7fffffff - (local_4a8 + iVar2)" identifier <= (binary_expression "0x7fffffff - (local_4a8 + iVar2)" number_literal - (parenthesized_expression "(local_4a8 + iVar2)" ( (binary_expression "local_4a8 + iVar2" identifier + identifier) )))) ))) )) (compound_statement "{\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }" { (expression_statement "iVar6 = local_4a8 + iVar2 + local_498;" (assignment_expression "iVar6 = local_4a8 + iVar2 + local_498" identifier = (binary_expression "local_4a8 + iVar2 + local_498" (binary_expression "local_4a8 + iVar2" identifier + identifier) + identifier)) ;) })) (if_statement "if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" if (parenthesized_expression "(bVar1)" ( identifier )) (compound_statement "{\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }" { (expression_statement "iVar5 = FUN_0003a060();" (assignment_expression "iVar5 = FUN_0003a060()" identifier = (call_expression "FUN_0003a060()" identifier (argument_list "()" ( )))) ;) (if_statement "if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }" if (parenthesized_expression "((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0))" ( (binary_expression "(iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)" (parenthesized_expression "(iVar5 != 0)" ( (binary_expression "iVar5 != 0" identifier != number_literal) )) || (parenthesized_expression "(iVar5 = FUN_0003a340(), iVar5 != 0)" ( (comma_expression "iVar5 = FUN_0003a340(), iVar5 != 0" (assignment_expression "iVar5 = FUN_0003a340()" identifier = (call_expression "FUN_0003a340()" identifier (argument_list "()" ( )))) , (binary_expression "iVar5 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }" { comment (expression_statement "png_error(param_1,*(undefined4 *)(param_1 + 0xf8));" (call_expression "png_error(param_1,*(undefined4 *)(param_1 + 0xf8))" identifier (argument_list "(param_1,*(undefined4 *)(param_1 + 0xf8))" ( identifier , (pointer_expression "*(undefined4 *)(param_1 + 0xf8)" * (cast_expression "(undefined4 *)(param_1 + 0xf8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xf8)" ( (binary_expression "param_1 + 0xf8" identifier + number_literal) )))) ))) ;) })) (if_statement "if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" if (parenthesized_expression "(param_1 == 0)" ( (binary_expression "param_1 == 0" identifier == number_literal) )) (compound_statement "{\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }" { (expression_statement "png_write_chunk_data(0,&local_72,iVar2);" (call_expression "png_write_chunk_data(0,&local_72,iVar2)" identifier (argument_list "(0,&local_72,iVar2)" ( number_literal , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(0,local_4a4,local_4a8)" identifier (argument_list "(0,local_4a4,local_4a8)" ( number_literal , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a0,local_498);" (call_expression "png_write_chunk_data(0,local_4a0,local_498)" identifier (argument_list "(0,local_4a0,local_498)" ( number_literal , identifier , identifier ))) ;) }) (else_clause "else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" else (compound_statement "{\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" { (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x22;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x22" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_save_uint_32(local_7a,iVar6);" (call_expression "png_save_uint_32(local_7a,iVar6)" identifier (argument_list "(local_7a,iVar6)" ( identifier , identifier ))) ;) (expression_statement "png_save_uint_32(local_76,0x69545874);" (call_expression "png_save_uint_32(local_76,0x69545874)" identifier (argument_list "(local_76,0x69545874)" ( identifier , number_literal ))) ;) (expression_statement "FUN_000360c0(param_1,local_7a,8);" (call_expression "FUN_000360c0(param_1,local_7a,8)" identifier (argument_list "(param_1,local_7a,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x178) = 0x69545874;" (assignment_expression "*(undefined4 *)(param_1 + 0x178) = 0x69545874" (pointer_expression "*(undefined4 *)(param_1 + 0x178)" * (cast_expression "(undefined4 *)(param_1 + 0x178)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x178)" ( (binary_expression "param_1 + 0x178" identifier + number_literal) )))) = number_literal) ;) (expression_statement "FUN_00014f90(param_1);" (call_expression "FUN_00014f90(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (expression_statement "FUN_00014fc0(param_1,local_76,4);" (call_expression "FUN_00014fc0(param_1,local_76,4)" identifier (argument_list "(param_1,local_76,4)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x42;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x42" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_write_chunk_data(param_1,&local_72,iVar2);" (call_expression "png_write_chunk_data(param_1,&local_72,iVar2)" identifier (argument_list "(param_1,&local_72,iVar2)" ( identifier , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(param_1,local_4a4,local_4a8)" identifier (argument_list "(param_1,local_4a4,local_4a8)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a0,local_498);" (call_expression "png_write_chunk_data(param_1,local_4a0,local_498)" identifier (argument_list "(param_1,local_4a0,local_498)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_data(param_1,local_47c,0);" (call_expression "png_write_chunk_data(param_1,local_47c,0)" identifier (argument_list "(param_1,local_47c,0)" ( identifier , identifier , number_literal ))) ;) }) (else_clause "else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" else (compound_statement "{\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" { (if_statement "if (0x7fffffffU - iVar6 < uVar4) {\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }" if (parenthesized_expression "(0x7fffffffU - iVar6 < uVar4)" ( (binary_expression "0x7fffffffU - iVar6 < uVar4" (binary_expression "0x7fffffffU - iVar6" number_literal - identifier) < identifier) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }" { comment (expression_statement "png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);" (call_expression "png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4)" identifier (argument_list "(param_1,"iTXt: uncompressed text too long",uVar4,uVar4)" ( identifier , (string_literal ""iTXt: uncompressed text too long"" " string_content ") , identifier , identifier ))) ;) })) (if_statement "if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" if (parenthesized_expression "(param_1 == 0)" ( (binary_expression "param_1 == 0" identifier == number_literal) )) (compound_statement "{\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }" { (expression_statement "png_write_chunk_data(0,&local_72,iVar2);" (call_expression "png_write_chunk_data(0,&local_72,iVar2)" identifier (argument_list "(0,&local_72,iVar2)" ( number_literal , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(0,local_4a4,local_4a8)" identifier (argument_list "(0,local_4a4,local_4a8)" ( number_literal , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a0,local_498);" (call_expression "png_write_chunk_data(0,local_4a0,local_498)" identifier (argument_list "(0,local_4a0,local_498)" ( number_literal , identifier , identifier ))) ;) }) (else_clause "else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" else (compound_statement "{\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" { (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x22;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x22" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_save_uint_32(local_7a,uVar4 + iVar6);" (call_expression "png_save_uint_32(local_7a,uVar4 + iVar6)" identifier (argument_list "(local_7a,uVar4 + iVar6)" ( identifier , (binary_expression "uVar4 + iVar6" identifier + identifier) ))) ;) (expression_statement "png_save_uint_32(local_76,0x69545874);" (call_expression "png_save_uint_32(local_76,0x69545874)" identifier (argument_list "(local_76,0x69545874)" ( identifier , number_literal ))) ;) (expression_statement "FUN_000360c0(param_1,local_7a,8);" (call_expression "FUN_000360c0(param_1,local_7a,8)" identifier (argument_list "(param_1,local_7a,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x178) = 0x69545874;" (assignment_expression "*(undefined4 *)(param_1 + 0x178) = 0x69545874" (pointer_expression "*(undefined4 *)(param_1 + 0x178)" * (cast_expression "(undefined4 *)(param_1 + 0x178)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x178)" ( (binary_expression "param_1 + 0x178" identifier + number_literal) )))) = number_literal) ;) (expression_statement "FUN_00014f90(param_1);" (call_expression "FUN_00014f90(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (expression_statement "FUN_00014fc0(param_1,local_76,4);" (call_expression "FUN_00014fc0(param_1,local_76,4)" identifier (argument_list "(param_1,local_76,4)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x42;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x42" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_write_chunk_data(param_1,&local_72,iVar2);" (call_expression "png_write_chunk_data(param_1,&local_72,iVar2)" identifier (argument_list "(param_1,&local_72,iVar2)" ( identifier , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(param_1,local_4a4,local_4a8)" identifier (argument_list "(param_1,local_4a4,local_4a8)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a0,local_498);" (call_expression "png_write_chunk_data(param_1,local_4a0,local_498)" identifier (argument_list "(param_1,local_4a0,local_498)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_data(param_1,param_6,uVar4);" (call_expression "png_write_chunk_data(param_1,param_6,uVar4)" identifier (argument_list "(param_1,param_6,uVar4)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_end(param_1);" (call_expression "png_write_chunk_end(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0003f340();\n  }" if (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    FUN_0003f340();\n  }" { comment (expression_statement "FUN_0003f340();" (call_expression "FUN_0003f340()" identifier (argument_list "()" ( ))) ;) })) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nvoid png_write_iTXt(png_structrp png_ptr,int compression,png_const_charp key,png_const_charp lang,\n                   png_const_charp lang_key,png_const_charp text)\n\n{\n  int iVar1;\n  bool bVar2;\n  png_uint_32 pVar3;\n  size_t length;\n  size_t sVar4;\n  int iVar5;\n  png_byte *data;\n  compression_state *comp_00;\n  uint length_00;\n  png_compression_bufferp ppVar6;\n  int in_GS_OFFSET;\n  png_uint_32 in_stack_fffffb54;\n  uint local_4a8;\n  png_const_bytep local_4a4;\n  png_const_bytep local_4a0;\n  uint local_498;\n  compression_state comp;\n  png_byte buf [8];\n  png_byte new_key [82];\n  \n  local_4a4 = (png_const_bytep)lang;\n  local_4a0 = (png_const_bytep)lang_key;\n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  pVar3 = png_check_keyword(png_ptr,key,new_key);\n  if (pVar3 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(png_ptr,"iTXt: invalid keyword");\n  }\n  if (compression == 0) {\nLAB_0003c58f:\n    bVar2 = true;\n    new_key[pVar3 + 1] = '\x01';\n  }\n  else {\n    if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar2 = false;\n    new_key[pVar3 + 1] = '\0';\n  }\n  new_key[pVar3 + 2] = '\0';\n  length = pVar3 + 3;\n  if (lang == (png_const_charp)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar4 = strlen(lang);\n    local_4a8 = sVar4 + 1;\n  }\n  if (lang_key == (png_const_charp)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar4 = strlen(lang_key);\n    local_498 = sVar4 + 1;\n  }\n  if (text == (png_const_charp)0x0) {\n    comp.input_len = 0;\n    text = "";\n  }\n  else {\n    comp.input_len = strlen(text);\n  }\n  comp_00 = (compression_state *)0x7fffffff;\n  if ((local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length))) {\n    comp_00 = (compression_state *)(local_4a8 + length + local_498);\n  }\n  comp.output_len = 0;\n  comp.input = (png_const_bytep)text;\n  if (bVar2) {\n    iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);\n    if ((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       ) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    pVar3 = comp.output_len;\n    if (comp.output_len < 0x400) {\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }\n    else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }\n  }\n  else {\n    if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }\n    comp.output_len = comp.input_len;\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);\n  }\n  png_write_chunk_end(png_ptr);\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return;\n}\n\n" comment (function_definition "void png_write_iTXt(png_structrp png_ptr,int compression,png_const_charp key,png_const_charp lang,\n                   png_const_charp lang_key,png_const_charp text)\n\n{\n  int iVar1;\n  bool bVar2;\n  png_uint_32 pVar3;\n  size_t length;\n  size_t sVar4;\n  int iVar5;\n  png_byte *data;\n  compression_state *comp_00;\n  uint length_00;\n  png_compression_bufferp ppVar6;\n  int in_GS_OFFSET;\n  png_uint_32 in_stack_fffffb54;\n  uint local_4a8;\n  png_const_bytep local_4a4;\n  png_const_bytep local_4a0;\n  uint local_498;\n  compression_state comp;\n  png_byte buf [8];\n  png_byte new_key [82];\n  \n  local_4a4 = (png_const_bytep)lang;\n  local_4a0 = (png_const_bytep)lang_key;\n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  pVar3 = png_check_keyword(png_ptr,key,new_key);\n  if (pVar3 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(png_ptr,"iTXt: invalid keyword");\n  }\n  if (compression == 0) {\nLAB_0003c58f:\n    bVar2 = true;\n    new_key[pVar3 + 1] = '\x01';\n  }\n  else {\n    if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar2 = false;\n    new_key[pVar3 + 1] = '\0';\n  }\n  new_key[pVar3 + 2] = '\0';\n  length = pVar3 + 3;\n  if (lang == (png_const_charp)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar4 = strlen(lang);\n    local_4a8 = sVar4 + 1;\n  }\n  if (lang_key == (png_const_charp)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar4 = strlen(lang_key);\n    local_498 = sVar4 + 1;\n  }\n  if (text == (png_const_charp)0x0) {\n    comp.input_len = 0;\n    text = "";\n  }\n  else {\n    comp.input_len = strlen(text);\n  }\n  comp_00 = (compression_state *)0x7fffffff;\n  if ((local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length))) {\n    comp_00 = (compression_state *)(local_4a8 + length + local_498);\n  }\n  comp.output_len = 0;\n  comp.input = (png_const_bytep)text;\n  if (bVar2) {\n    iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);\n    if ((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       ) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    pVar3 = comp.output_len;\n    if (comp.output_len < 0x400) {\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }\n    else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }\n  }\n  else {\n    if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }\n    comp.output_len = comp.input_len;\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);\n  }\n  png_write_chunk_end(png_ptr);\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return;\n}" primitive_type (function_declarator "png_write_iTXt(png_structrp png_ptr,int compression,png_const_charp key,png_const_charp lang,\n                   png_const_charp lang_key,png_const_charp text)" identifier (parameter_list "(png_structrp png_ptr,int compression,png_const_charp key,png_const_charp lang,\n                   png_const_charp lang_key,png_const_charp text)" ( (parameter_declaration "png_structrp png_ptr" type_identifier identifier) , (parameter_declaration "int compression" primitive_type identifier) , (parameter_declaration "png_const_charp key" type_identifier identifier) , (parameter_declaration "png_const_charp lang" type_identifier identifier) , (parameter_declaration "png_const_charp lang_key" type_identifier identifier) , (parameter_declaration "png_const_charp text" type_identifier identifier) ))) (compound_statement "{\n  int iVar1;\n  bool bVar2;\n  png_uint_32 pVar3;\n  size_t length;\n  size_t sVar4;\n  int iVar5;\n  png_byte *data;\n  compression_state *comp_00;\n  uint length_00;\n  png_compression_bufferp ppVar6;\n  int in_GS_OFFSET;\n  png_uint_32 in_stack_fffffb54;\n  uint local_4a8;\n  png_const_bytep local_4a4;\n  png_const_bytep local_4a0;\n  uint local_498;\n  compression_state comp;\n  png_byte buf [8];\n  png_byte new_key [82];\n  \n  local_4a4 = (png_const_bytep)lang;\n  local_4a0 = (png_const_bytep)lang_key;\n  iVar1 = *(int *)(in_GS_OFFSET + 0x14);\n  pVar3 = png_check_keyword(png_ptr,key,new_key);\n  if (pVar3 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(png_ptr,"iTXt: invalid keyword");\n  }\n  if (compression == 0) {\nLAB_0003c58f:\n    bVar2 = true;\n    new_key[pVar3 + 1] = '\x01';\n  }\n  else {\n    if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar2 = false;\n    new_key[pVar3 + 1] = '\0';\n  }\n  new_key[pVar3 + 2] = '\0';\n  length = pVar3 + 3;\n  if (lang == (png_const_charp)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar4 = strlen(lang);\n    local_4a8 = sVar4 + 1;\n  }\n  if (lang_key == (png_const_charp)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar4 = strlen(lang_key);\n    local_498 = sVar4 + 1;\n  }\n  if (text == (png_const_charp)0x0) {\n    comp.input_len = 0;\n    text = "";\n  }\n  else {\n    comp.input_len = strlen(text);\n  }\n  comp_00 = (compression_state *)0x7fffffff;\n  if ((local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length))) {\n    comp_00 = (compression_state *)(local_4a8 + length + local_498);\n  }\n  comp.output_len = 0;\n  comp.input = (png_const_bytep)text;\n  if (bVar2) {\n    iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);\n    if ((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       ) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    pVar3 = comp.output_len;\n    if (comp.output_len < 0x400) {\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }\n    else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }\n  }\n  else {\n    if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }\n    comp.output_len = comp.input_len;\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);\n  }\n  png_write_chunk_end(png_ptr);\n  if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "bool bVar2;" primitive_type identifier ;) (declaration "png_uint_32 pVar3;" type_identifier identifier ;) (declaration "size_t length;" primitive_type identifier ;) (declaration "size_t sVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "png_byte *data;" type_identifier (pointer_declarator "*data" * identifier) ;) (declaration "compression_state *comp_00;" type_identifier (pointer_declarator "*comp_00" * identifier) ;) (declaration "uint length_00;" type_identifier identifier ;) (declaration "png_compression_bufferp ppVar6;" type_identifier identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "png_uint_32 in_stack_fffffb54;" type_identifier identifier ;) (declaration "uint local_4a8;" type_identifier identifier ;) (declaration "png_const_bytep local_4a4;" type_identifier identifier ;) (declaration "png_const_bytep local_4a0;" type_identifier identifier ;) (declaration "uint local_498;" type_identifier identifier ;) (declaration "compression_state comp;" type_identifier identifier ;) (declaration "png_byte buf [8];" type_identifier (array_declarator "buf [8]" identifier [ number_literal ]) ;) (declaration "png_byte new_key [82];" type_identifier (array_declarator "new_key [82]" identifier [ number_literal ]) ;) (expression_statement "local_4a4 = (png_const_bytep)lang;" (assignment_expression "local_4a4 = (png_const_bytep)lang" identifier = (cast_expression "(png_const_bytep)lang" ( (type_descriptor "png_const_bytep" type_identifier) ) identifier)) ;) (expression_statement "local_4a0 = (png_const_bytep)lang_key;" (assignment_expression "local_4a0 = (png_const_bytep)lang_key" identifier = (cast_expression "(png_const_bytep)lang_key" ( (type_descriptor "png_const_bytep" 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 "pVar3 = png_check_keyword(png_ptr,key,new_key);" (assignment_expression "pVar3 = png_check_keyword(png_ptr,key,new_key)" identifier = (call_expression "png_check_keyword(png_ptr,key,new_key)" identifier (argument_list "(png_ptr,key,new_key)" ( identifier , identifier , identifier )))) ;) (if_statement "if (pVar3 == 0) {\n                    /* WARNING: Subroutine does not return */\n    png_error(png_ptr,"iTXt: invalid keyword");\n  }" if (parenthesized_expression "(pVar3 == 0)" ( (binary_expression "pVar3 == 0" identifier == number_literal) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    png_error(png_ptr,"iTXt: invalid keyword");\n  }" { comment (expression_statement "png_error(png_ptr,"iTXt: invalid keyword");" (call_expression "png_error(png_ptr,"iTXt: invalid keyword")" identifier (argument_list "(png_ptr,"iTXt: invalid keyword")" ( identifier , (string_literal ""iTXt: invalid keyword"" " string_content ") ))) ;) })) (if_statement "if (compression == 0) {\nLAB_0003c58f:\n    bVar2 = true;\n    new_key[pVar3 + 1] = '\x01';\n  }\n  else {\n    if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar2 = false;\n    new_key[pVar3 + 1] = '\0';\n  }" if (parenthesized_expression "(compression == 0)" ( (binary_expression "compression == 0" identifier == number_literal) )) (compound_statement "{\nLAB_0003c58f:\n    bVar2 = true;\n    new_key[pVar3 + 1] = '\x01';\n  }" { (labeled_statement "LAB_0003c58f:\n    bVar2 = true;" statement_identifier : (expression_statement "bVar2 = true;" (assignment_expression "bVar2 = true" identifier = true) ;)) (expression_statement "new_key[pVar3 + 1] = '\x01';" (assignment_expression "new_key[pVar3 + 1] = '\x01'" (subscript_expression "new_key[pVar3 + 1]" identifier [ (binary_expression "pVar3 + 1" identifier + number_literal) ]) = (char_literal "'\x01'" ' escape_sequence ')) ;) }) (else_clause "else {\n    if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar2 = false;\n    new_key[pVar3 + 1] = '\0';\n  }" else (compound_statement "{\n    if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar2 = false;\n    new_key[pVar3 + 1] = '\0';\n  }" { (if_statement "if (compression < 1) {\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }\n    else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" if (parenthesized_expression "(compression < 1)" ( (binary_expression "compression < 1" identifier < number_literal) )) (compound_statement "{\n      if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }\n    }" { (if_statement "if (compression != -1) {\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }" if (parenthesized_expression "(compression != -1)" ( (binary_expression "compression != -1" identifier != number_literal) )) (compound_statement "{\nLAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");\n      }" { (labeled_statement "LAB_0003c9ae:\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"iTXt: invalid compression");" statement_identifier : comment (expression_statement "png_error(png_ptr,"iTXt: invalid compression");" (call_expression "png_error(png_ptr,"iTXt: invalid compression")" identifier (argument_list "(png_ptr,"iTXt: invalid compression")" ( identifier , (string_literal ""iTXt: invalid compression"" " string_content ") ))) ;)) })) }) (else_clause "else if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" else (if_statement "if (compression != 1) {\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" if (parenthesized_expression "(compression != 1)" ( (binary_expression "compression != 1" identifier != number_literal) )) (compound_statement "{\n      if (compression != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" { (if_statement "if (compression != 2) goto LAB_0003c9ae;" if (parenthesized_expression "(compression != 2)" ( (binary_expression "compression != 2" identifier != number_literal) )) (goto_statement "goto LAB_0003c9ae;" goto statement_identifier ;)) (goto_statement "goto LAB_0003c58f;" goto statement_identifier ;) })))) (expression_statement "bVar2 = false;" (assignment_expression "bVar2 = false" identifier = false) ;) (expression_statement "new_key[pVar3 + 1] = '\0';" (assignment_expression "new_key[pVar3 + 1] = '\0'" (subscript_expression "new_key[pVar3 + 1]" identifier [ (binary_expression "pVar3 + 1" identifier + number_literal) ]) = (char_literal "'\0'" ' escape_sequence ')) ;) }))) (expression_statement "new_key[pVar3 + 2] = '\0';" (assignment_expression "new_key[pVar3 + 2] = '\0'" (subscript_expression "new_key[pVar3 + 2]" identifier [ (binary_expression "pVar3 + 2" identifier + number_literal) ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "length = pVar3 + 3;" (assignment_expression "length = pVar3 + 3" identifier = (binary_expression "pVar3 + 3" identifier + number_literal)) ;) (if_statement "if (lang == (png_const_charp)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar4 = strlen(lang);\n    local_4a8 = sVar4 + 1;\n  }" if (parenthesized_expression "(lang == (png_const_charp)0x0)" ( (binary_expression "lang == (png_const_charp)0x0" identifier == (cast_expression "(png_const_charp)0x0" ( (type_descriptor "png_const_charp" type_identifier) ) number_literal)) )) (compound_statement "{\n    local_4a4 = "";\n    local_4a8 = 1;\n  }" { (expression_statement "local_4a4 = "";" (assignment_expression "local_4a4 = """ identifier = (string_literal """" " ")) ;) (expression_statement "local_4a8 = 1;" (assignment_expression "local_4a8 = 1" identifier = number_literal) ;) }) (else_clause "else {\n    sVar4 = strlen(lang);\n    local_4a8 = sVar4 + 1;\n  }" else (compound_statement "{\n    sVar4 = strlen(lang);\n    local_4a8 = sVar4 + 1;\n  }" { (expression_statement "sVar4 = strlen(lang);" (assignment_expression "sVar4 = strlen(lang)" identifier = (call_expression "strlen(lang)" identifier (argument_list "(lang)" ( identifier )))) ;) (expression_statement "local_4a8 = sVar4 + 1;" (assignment_expression "local_4a8 = sVar4 + 1" identifier = (binary_expression "sVar4 + 1" identifier + number_literal)) ;) }))) (if_statement "if (lang_key == (png_const_charp)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar4 = strlen(lang_key);\n    local_498 = sVar4 + 1;\n  }" if (parenthesized_expression "(lang_key == (png_const_charp)0x0)" ( (binary_expression "lang_key == (png_const_charp)0x0" identifier == (cast_expression "(png_const_charp)0x0" ( (type_descriptor "png_const_charp" type_identifier) ) number_literal)) )) (compound_statement "{\n    local_4a0 = "";\n    local_498 = 1;\n  }" { (expression_statement "local_4a0 = "";" (assignment_expression "local_4a0 = """ identifier = (string_literal """" " ")) ;) (expression_statement "local_498 = 1;" (assignment_expression "local_498 = 1" identifier = number_literal) ;) }) (else_clause "else {\n    sVar4 = strlen(lang_key);\n    local_498 = sVar4 + 1;\n  }" else (compound_statement "{\n    sVar4 = strlen(lang_key);\n    local_498 = sVar4 + 1;\n  }" { (expression_statement "sVar4 = strlen(lang_key);" (assignment_expression "sVar4 = strlen(lang_key)" identifier = (call_expression "strlen(lang_key)" identifier (argument_list "(lang_key)" ( identifier )))) ;) (expression_statement "local_498 = sVar4 + 1;" (assignment_expression "local_498 = sVar4 + 1" identifier = (binary_expression "sVar4 + 1" identifier + number_literal)) ;) }))) (if_statement "if (text == (png_const_charp)0x0) {\n    comp.input_len = 0;\n    text = "";\n  }\n  else {\n    comp.input_len = strlen(text);\n  }" if (parenthesized_expression "(text == (png_const_charp)0x0)" ( (binary_expression "text == (png_const_charp)0x0" identifier == (cast_expression "(png_const_charp)0x0" ( (type_descriptor "png_const_charp" type_identifier) ) number_literal)) )) (compound_statement "{\n    comp.input_len = 0;\n    text = "";\n  }" { (expression_statement "comp.input_len = 0;" (assignment_expression "comp.input_len = 0" (field_expression "comp.input_len" identifier . field_identifier) = number_literal) ;) (expression_statement "text = "";" (assignment_expression "text = """ identifier = (string_literal """" " ")) ;) }) (else_clause "else {\n    comp.input_len = strlen(text);\n  }" else (compound_statement "{\n    comp.input_len = strlen(text);\n  }" { (expression_statement "comp.input_len = strlen(text);" (assignment_expression "comp.input_len = strlen(text)" (field_expression "comp.input_len" identifier . field_identifier) = (call_expression "strlen(text)" identifier (argument_list "(text)" ( identifier )))) ;) }))) (expression_statement "comp_00 = (compression_state *)0x7fffffff;" (assignment_expression "comp_00 = (compression_state *)0x7fffffff" identifier = (cast_expression "(compression_state *)0x7fffffff" ( (type_descriptor "compression_state *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (if_statement "if ((local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length))) {\n    comp_00 = (compression_state *)(local_4a8 + length + local_498);\n  }" if (parenthesized_expression "((local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length)))" ( (binary_expression "(local_4a8 <= 0x7fffffff - length) && (local_498 <= 0x7fffffff - (local_4a8 + length))" (parenthesized_expression "(local_4a8 <= 0x7fffffff - length)" ( (binary_expression "local_4a8 <= 0x7fffffff - length" identifier <= (binary_expression "0x7fffffff - length" number_literal - identifier)) )) && (parenthesized_expression "(local_498 <= 0x7fffffff - (local_4a8 + length))" ( (binary_expression "local_498 <= 0x7fffffff - (local_4a8 + length)" identifier <= (binary_expression "0x7fffffff - (local_4a8 + length)" number_literal - (parenthesized_expression "(local_4a8 + length)" ( (binary_expression "local_4a8 + length" identifier + identifier) )))) ))) )) (compound_statement "{\n    comp_00 = (compression_state *)(local_4a8 + length + local_498);\n  }" { (expression_statement "comp_00 = (compression_state *)(local_4a8 + length + local_498);" (assignment_expression "comp_00 = (compression_state *)(local_4a8 + length + local_498)" identifier = (cast_expression "(compression_state *)(local_4a8 + length + local_498)" ( (type_descriptor "compression_state *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(local_4a8 + length + local_498)" ( (binary_expression "local_4a8 + length + local_498" (binary_expression "local_4a8 + length" identifier + identifier) + identifier) )))) ;) })) (expression_statement "comp.output_len = 0;" (assignment_expression "comp.output_len = 0" (field_expression "comp.output_len" identifier . field_identifier) = number_literal) ;) (expression_statement "comp.input = (png_const_bytep)text;" (assignment_expression "comp.input = (png_const_bytep)text" (field_expression "comp.input" identifier . field_identifier) = (cast_expression "(png_const_bytep)text" ( (type_descriptor "png_const_bytep" type_identifier) ) identifier)) ;) (if_statement "if (bVar2) {\n    iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);\n    if ((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       ) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    pVar3 = comp.output_len;\n    if (comp.output_len < 0x400) {\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }\n    else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }\n  }\n  else {\n    if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }\n    comp.output_len = comp.input_len;\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);\n  }" if (parenthesized_expression "(bVar2)" ( identifier )) (compound_statement "{\n    iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);\n    if ((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       ) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    pVar3 = comp.output_len;\n    if (comp.output_len < 0x400) {\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }\n    else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }\n  }" { (expression_statement "iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len);" (assignment_expression "iVar5 = png_deflate_claim(png_ptr,0x69545874,comp.input_len)" identifier = (call_expression "png_deflate_claim(png_ptr,0x69545874,comp.input_len)" identifier (argument_list "(png_ptr,0x69545874,comp.input_len)" ( identifier , number_literal , (field_expression "comp.input_len" identifier . field_identifier) )))) ;) (if_statement "if ((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       ) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }" if (parenthesized_expression "((iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)\n       )" ( (binary_expression "(iVar5 != 0) ||\n       (iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)" (parenthesized_expression "(iVar5 != 0)" ( (binary_expression "iVar5 != 0" identifier != number_literal) )) || (parenthesized_expression "(iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0)" ( (comma_expression "iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54), iVar5 != 0" (assignment_expression "iVar5 = png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54)" identifier = (call_expression "png_text_compress(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54)" identifier (argument_list "(png_ptr,(png_uint_32)&comp,comp_00,in_stack_fffffb54)" ( identifier , (binary_expression "(png_uint_32)&comp" (parenthesized_expression "(png_uint_32)" ( identifier )) & identifier) , identifier , identifier )))) , (binary_expression "iVar5 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,(png_ptr->zstream).msg);\n    }" { comment (expression_statement "png_error(png_ptr,(png_ptr->zstream).msg);" (call_expression "png_error(png_ptr,(png_ptr->zstream).msg)" identifier (argument_list "(png_ptr,(png_ptr->zstream).msg)" ( identifier , (field_expression "(png_ptr->zstream).msg" (parenthesized_expression "(png_ptr->zstream)" ( (field_expression "png_ptr->zstream" identifier -> field_identifier) )) . field_identifier) ))) ;) })) (if_statement "if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }" if (parenthesized_expression "(png_ptr == (png_structrp)0x0)" ( (binary_expression "png_ptr == (png_structrp)0x0" identifier == (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal)) )) (compound_statement "{\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }" { (expression_statement "png_write_chunk_data((png_structrp)0x0,new_key,length);" (call_expression "png_write_chunk_data((png_structrp)0x0,new_key,length)" identifier (argument_list "((png_structrp)0x0,new_key,length)" ( (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal) , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8)" identifier (argument_list "((png_structrp)0x0,local_4a4,local_4a8)" ( (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal) , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);" (call_expression "png_write_chunk_data((png_structrp)0x0,local_4a0,local_498)" identifier (argument_list "((png_structrp)0x0,local_4a0,local_498)" ( (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal) , identifier , identifier ))) ;) }) (else_clause "else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }" else (compound_statement "{\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }" { (expression_statement "png_ptr->io_state = 0x22;" (assignment_expression "png_ptr->io_state = 0x22" (field_expression "png_ptr->io_state" identifier -> field_identifier) = number_literal) ;) (expression_statement "png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)));" (call_expression "png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)))" identifier (argument_list "(buf,(png_uint_32)(comp_00->output + (comp.output_len - 0xc)))" ( identifier , (call_expression "(png_uint_32)(comp_00->output + (comp.output_len - 0xc))" (parenthesized_expression "(png_uint_32)" ( identifier )) (argument_list "(comp_00->output + (comp.output_len - 0xc))" ( (binary_expression "comp_00->output + (comp.output_len - 0xc)" (field_expression "comp_00->output" identifier -> field_identifier) + (parenthesized_expression "(comp.output_len - 0xc)" ( (binary_expression "comp.output_len - 0xc" (field_expression "comp.output_len" identifier . field_identifier) - number_literal) ))) ))) ))) ;) (expression_statement "png_save_uint_32(buf + 4,0x69545874);" (call_expression "png_save_uint_32(buf + 4,0x69545874)" identifier (argument_list "(buf + 4,0x69545874)" ( (binary_expression "buf + 4" identifier + number_literal) , number_literal ))) ;) (expression_statement "png_write_data(png_ptr,buf,8);" (call_expression "png_write_data(png_ptr,buf,8)" identifier (argument_list "(png_ptr,buf,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "png_ptr->chunk_name = 0x69545874;" (assignment_expression "png_ptr->chunk_name = 0x69545874" (field_expression "png_ptr->chunk_name" identifier -> field_identifier) = number_literal) ;) (expression_statement "png_reset_crc(png_ptr);" (call_expression "png_reset_crc(png_ptr)" identifier (argument_list "(png_ptr)" ( identifier ))) ;) (expression_statement "png_calculate_crc(png_ptr,buf + 4,4);" (call_expression "png_calculate_crc(png_ptr,buf + 4,4)" identifier (argument_list "(png_ptr,buf + 4,4)" ( identifier , (binary_expression "buf + 4" identifier + number_literal) , number_literal ))) ;) (expression_statement "png_ptr->io_state = 0x42;" (assignment_expression "png_ptr->io_state = 0x42" (field_expression "png_ptr->io_state" identifier -> field_identifier) = number_literal) ;) (expression_statement "png_write_chunk_data(png_ptr,new_key,length);" (call_expression "png_write_chunk_data(png_ptr,new_key,length)" identifier (argument_list "(png_ptr,new_key,length)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(png_ptr,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(png_ptr,local_4a4,local_4a8)" identifier (argument_list "(png_ptr,local_4a4,local_4a8)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(png_ptr,local_4a0,local_498);" (call_expression "png_write_chunk_data(png_ptr,local_4a0,local_498)" identifier (argument_list "(png_ptr,local_4a0,local_498)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "pVar3 = comp.output_len;" (assignment_expression "pVar3 = comp.output_len" identifier = (field_expression "comp.output_len" identifier . field_identifier)) ;) (if_statement "if (comp.output_len < 0x400) {\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }\n    else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }" if (parenthesized_expression "(comp.output_len < 0x400)" ( (binary_expression "comp.output_len < 0x400" (field_expression "comp.output_len" identifier . field_identifier) < number_literal) )) (compound_statement "{\n      data = comp.output;\nLAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);\n    }" { (expression_statement "data = comp.output;" (assignment_expression "data = comp.output" identifier = (field_expression "comp.output" identifier . field_identifier)) ;) (labeled_statement "LAB_0003c8f2:\n      png_write_chunk_data(png_ptr,data,pVar3);" statement_identifier : (expression_statement "png_write_chunk_data(png_ptr,data,pVar3);" (call_expression "png_write_chunk_data(png_ptr,data,pVar3)" identifier (argument_list "(png_ptr,data,pVar3)" ( identifier , identifier , identifier ))) ;)) }) (else_clause "else {\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }" else (compound_statement "{\n      ppVar6 = png_ptr->zbuffer_list;\n      data = comp.output;\n      length_00 = 0x400;\n      while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }\n      if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }\n    }" { (expression_statement "ppVar6 = png_ptr->zbuffer_list;" (assignment_expression "ppVar6 = png_ptr->zbuffer_list" identifier = (field_expression "png_ptr->zbuffer_list" identifier -> field_identifier)) ;) (expression_statement "data = comp.output;" (assignment_expression "data = comp.output" identifier = (field_expression "comp.output" identifier . field_identifier)) ;) (expression_statement "length_00 = 0x400;" (assignment_expression "length_00 = 0x400" identifier = number_literal) ;) (while_statement "while( true ) {\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n        png_write_chunk_data(png_ptr,data,length_00);\n        pVar3 = pVar3 - length_00;\n        if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;\n        length_00 = png_ptr->zbuffer_size;\n        data = ppVar6->output;\n        if (pVar3 < length_00) goto LAB_0003c8f2;\n        ppVar6 = ppVar6->next;\n      }" { (expression_statement "png_write_chunk_data(png_ptr,data,length_00);" (call_expression "png_write_chunk_data(png_ptr,data,length_00)" identifier (argument_list "(png_ptr,data,length_00)" ( identifier , identifier , identifier ))) ;) (expression_statement "pVar3 = pVar3 - length_00;" (assignment_expression "pVar3 = pVar3 - length_00" identifier = (binary_expression "pVar3 - length_00" identifier - identifier)) ;) (if_statement "if ((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)) break;" if (parenthesized_expression "((pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0))" ( (binary_expression "(pVar3 == 0) || (ppVar6 == (png_compression_bufferp)0x0)" (parenthesized_expression "(pVar3 == 0)" ( (binary_expression "pVar3 == 0" identifier == number_literal) )) || (parenthesized_expression "(ppVar6 == (png_compression_bufferp)0x0)" ( (binary_expression "ppVar6 == (png_compression_bufferp)0x0" identifier == (cast_expression "(png_compression_bufferp)0x0" ( (type_descriptor "png_compression_bufferp" type_identifier) ) number_literal)) ))) )) (break_statement "break;" break ;)) (expression_statement "length_00 = png_ptr->zbuffer_size;" (assignment_expression "length_00 = png_ptr->zbuffer_size" identifier = (field_expression "png_ptr->zbuffer_size" identifier -> field_identifier)) ;) (expression_statement "data = ppVar6->output;" (assignment_expression "data = ppVar6->output" identifier = (field_expression "ppVar6->output" identifier -> field_identifier)) ;) (if_statement "if (pVar3 < length_00) goto LAB_0003c8f2;" if (parenthesized_expression "(pVar3 < length_00)" ( (binary_expression "pVar3 < length_00" identifier < identifier) )) (goto_statement "goto LAB_0003c8f2;" goto statement_identifier ;)) (expression_statement "ppVar6 = ppVar6->next;" (assignment_expression "ppVar6 = ppVar6->next" identifier = (field_expression "ppVar6->next" identifier -> field_identifier)) ;) })) (if_statement "if (pVar3 != 0) {\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }" if (parenthesized_expression "(pVar3 != 0)" ( (binary_expression "pVar3 != 0" identifier != number_literal) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n        png_error(png_ptr,"error writing ancillary chunked compressed data");\n      }" { comment (expression_statement "png_error(png_ptr,"error writing ancillary chunked compressed data");" (call_expression "png_error(png_ptr,"error writing ancillary chunked compressed data")" identifier (argument_list "(png_ptr,"error writing ancillary chunked compressed data")" ( identifier , (string_literal ""error writing ancillary chunked compressed data"" " string_content ") ))) ;) })) }))) }) (else_clause "else {\n    if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }\n    comp.output_len = comp.input_len;\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);\n  }" else (compound_statement "{\n    if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }\n    comp.output_len = comp.input_len;\n    if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }\n    png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);\n  }" { (if_statement "if (0x7fffffffU - (int)comp_00 < comp.input_len) {\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }" if (parenthesized_expression "(0x7fffffffU - (int)comp_00 < comp.input_len)" ( (binary_expression "0x7fffffffU - (int)comp_00 < comp.input_len" (binary_expression "0x7fffffffU - (int)comp_00" number_literal - (cast_expression "(int)comp_00" ( (type_descriptor "int" primitive_type) ) identifier)) < (field_expression "comp.input_len" identifier . field_identifier)) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n      png_error(png_ptr,"iTXt: uncompressed text too long");\n    }" { comment (expression_statement "png_error(png_ptr,"iTXt: uncompressed text too long");" (call_expression "png_error(png_ptr,"iTXt: uncompressed text too long")" identifier (argument_list "(png_ptr,"iTXt: uncompressed text too long")" ( identifier , (string_literal ""iTXt: uncompressed text too long"" " string_content ") ))) ;) })) (expression_statement "comp.output_len = comp.input_len;" (assignment_expression "comp.output_len = comp.input_len" (field_expression "comp.output_len" identifier . field_identifier) = (field_expression "comp.input_len" identifier . field_identifier)) ;) (if_statement "if (png_ptr == (png_structrp)0x0) {\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }\n    else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }" if (parenthesized_expression "(png_ptr == (png_structrp)0x0)" ( (binary_expression "png_ptr == (png_structrp)0x0" identifier == (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal)) )) (compound_statement "{\n      png_write_chunk_data((png_structrp)0x0,new_key,length);\n      png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);\n      png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);\n    }" { (expression_statement "png_write_chunk_data((png_structrp)0x0,new_key,length);" (call_expression "png_write_chunk_data((png_structrp)0x0,new_key,length)" identifier (argument_list "((png_structrp)0x0,new_key,length)" ( (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal) , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data((png_structrp)0x0,local_4a4,local_4a8)" identifier (argument_list "((png_structrp)0x0,local_4a4,local_4a8)" ( (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal) , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data((png_structrp)0x0,local_4a0,local_498);" (call_expression "png_write_chunk_data((png_structrp)0x0,local_4a0,local_498)" identifier (argument_list "((png_structrp)0x0,local_4a0,local_498)" ( (cast_expression "(png_structrp)0x0" ( (type_descriptor "png_structrp" type_identifier) ) number_literal) , identifier , identifier ))) ;) }) (else_clause "else {\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }" else (compound_statement "{\n      png_ptr->io_state = 0x22;\n      png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));\n      png_save_uint_32(buf + 4,0x69545874);\n      png_write_data(png_ptr,buf,8);\n      png_ptr->chunk_name = 0x69545874;\n      png_reset_crc(png_ptr);\n      png_calculate_crc(png_ptr,buf + 4,4);\n      png_ptr->io_state = 0x42;\n      png_write_chunk_data(png_ptr,new_key,length);\n      png_write_chunk_data(png_ptr,local_4a4,local_4a8);\n      png_write_chunk_data(png_ptr,local_4a0,local_498);\n    }" { (expression_statement "png_ptr->io_state = 0x22;" (assignment_expression "png_ptr->io_state = 0x22" (field_expression "png_ptr->io_state" identifier -> field_identifier) = number_literal) ;) (expression_statement "png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)));" (call_expression "png_save_uint_32(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)))" identifier (argument_list "(buf,(png_uint_32)(comp_00->output + (comp.input_len - 0xc)))" ( identifier , (call_expression "(png_uint_32)(comp_00->output + (comp.input_len - 0xc))" (parenthesized_expression "(png_uint_32)" ( identifier )) (argument_list "(comp_00->output + (comp.input_len - 0xc))" ( (binary_expression "comp_00->output + (comp.input_len - 0xc)" (field_expression "comp_00->output" identifier -> field_identifier) + (parenthesized_expression "(comp.input_len - 0xc)" ( (binary_expression "comp.input_len - 0xc" (field_expression "comp.input_len" identifier . field_identifier) - number_literal) ))) ))) ))) ;) (expression_statement "png_save_uint_32(buf + 4,0x69545874);" (call_expression "png_save_uint_32(buf + 4,0x69545874)" identifier (argument_list "(buf + 4,0x69545874)" ( (binary_expression "buf + 4" identifier + number_literal) , number_literal ))) ;) (expression_statement "png_write_data(png_ptr,buf,8);" (call_expression "png_write_data(png_ptr,buf,8)" identifier (argument_list "(png_ptr,buf,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "png_ptr->chunk_name = 0x69545874;" (assignment_expression "png_ptr->chunk_name = 0x69545874" (field_expression "png_ptr->chunk_name" identifier -> field_identifier) = number_literal) ;) (expression_statement "png_reset_crc(png_ptr);" (call_expression "png_reset_crc(png_ptr)" identifier (argument_list "(png_ptr)" ( identifier ))) ;) (expression_statement "png_calculate_crc(png_ptr,buf + 4,4);" (call_expression "png_calculate_crc(png_ptr,buf + 4,4)" identifier (argument_list "(png_ptr,buf + 4,4)" ( identifier , (binary_expression "buf + 4" identifier + number_literal) , number_literal ))) ;) (expression_statement "png_ptr->io_state = 0x42;" (assignment_expression "png_ptr->io_state = 0x42" (field_expression "png_ptr->io_state" identifier -> field_identifier) = number_literal) ;) (expression_statement "png_write_chunk_data(png_ptr,new_key,length);" (call_expression "png_write_chunk_data(png_ptr,new_key,length)" identifier (argument_list "(png_ptr,new_key,length)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(png_ptr,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(png_ptr,local_4a4,local_4a8)" identifier (argument_list "(png_ptr,local_4a4,local_4a8)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(png_ptr,local_4a0,local_498);" (call_expression "png_write_chunk_data(png_ptr,local_4a0,local_498)" identifier (argument_list "(png_ptr,local_4a0,local_498)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len);" (call_expression "png_write_chunk_data(png_ptr,(png_const_bytep)text,comp.output_len)" identifier (argument_list "(png_ptr,(png_const_bytep)text,comp.output_len)" ( identifier , (cast_expression "(png_const_bytep)text" ( (type_descriptor "png_const_bytep" type_identifier) ) identifier) , (field_expression "comp.output_len" identifier . field_identifier) ))) ;) }))) (expression_statement "png_write_chunk_end(png_ptr);" (call_expression "png_write_chunk_end(png_ptr)" identifier (argument_list "(png_ptr)" ( identifier ))) ;) (if_statement "if (iVar1 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" if (parenthesized_expression "(iVar1 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "iVar1 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" { comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) })) (return_statement "return;" return ;) })))
(translation_unit "void FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)\n\n{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }\n  return;\n}\n\n" (function_definition "void FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)\n\n{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }\n  return;\n}" primitive_type (function_declarator "FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)" identifier (parameter_list "(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "char *param_4" primitive_type (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "char *param_5" primitive_type (pointer_declarator "*param_5" * identifier)) , (parameter_declaration "char *param_6" primitive_type (pointer_declarator "*param_6" * identifier)) ))) (compound_statement "{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }\n  return;\n}" { (declaration "bool bVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "size_t sVar3;" primitive_type identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "undefined4 extraout_ECX;" type_identifier identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "uint local_4a8;" type_identifier identifier ;) (declaration "char *local_4a4;" primitive_type (pointer_declarator "*local_4a4" * identifier) ;) (declaration "char *local_4a0;" primitive_type (pointer_declarator "*local_4a0" * identifier) ;) (declaration "uint local_498;" type_identifier identifier ;) (declaration "undefined1 local_47c [1026];" type_identifier (array_declarator "local_47c [1026]" identifier [ number_literal ]) ;) (declaration "undefined1 local_7a [4];" type_identifier (array_declarator "local_7a [4]" identifier [ number_literal ]) ;) (declaration "undefined1 local_76 [4];" type_identifier (array_declarator "local_76 [4]" identifier [ number_literal ]) ;) (declaration "undefined1 local_72;" type_identifier identifier ;) (declaration "undefined1 auStack_71 [81];" type_identifier (array_declarator "auStack_71 [81]" identifier [ number_literal ]) ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x3c509;" (assignment_expression "uStack_14 = 0x3c509" identifier = number_literal) ;) (expression_statement "local_4a4 = param_4;" (assignment_expression "local_4a4 = param_4" identifier = identifier) ;) (expression_statement "local_4a0 = param_5;" (assignment_expression "local_4a0 = param_5" identifier = identifier) ;) (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 "iVar2 = FUN_00035490(param_1,param_3,&local_72);" (assignment_expression "iVar2 = FUN_00035490(param_1,param_3,&local_72)" identifier = (call_expression "FUN_00035490(param_1,param_3,&local_72)" identifier (argument_list "(param_1,param_3,&local_72)" ( identifier , identifier , (pointer_expression "&local_72" & identifier) )))) ;) (if_statement "if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }" { (expression_statement "png_error(param_1,"iTXt: invalid keyword",param_6,param_6);" (call_expression "png_error(param_1,"iTXt: invalid keyword",param_6,param_6)" identifier (argument_list "(param_1,"iTXt: invalid keyword",param_6,param_6)" ( identifier , (string_literal ""iTXt: invalid keyword"" " string_content ") , identifier , identifier ))) ;) })) (if_statement "if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" if (parenthesized_expression "(param_2 == 0)" ( (binary_expression "param_2 == 0" identifier == number_literal) )) (compound_statement "{\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }" { (labeled_statement "LAB_0003c58f:\n    bVar1 = true;" statement_identifier : (expression_statement "bVar1 = true;" (assignment_expression "bVar1 = true" identifier = true) ;)) (expression_statement "auStack_71[iVar2] = 1;" (assignment_expression "auStack_71[iVar2] = 1" (subscript_expression "auStack_71[iVar2]" identifier [ identifier ]) = number_literal) ;) }) (else_clause "else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" else (compound_statement "{\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" { (if_statement "if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" if (parenthesized_expression "(param_2 < 1)" ( (binary_expression "param_2 < 1" identifier < number_literal) )) (compound_statement "{\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }" { (if_statement "if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }" if (parenthesized_expression "(param_2 != -1)" ( (binary_expression "param_2 != -1" identifier != number_literal) )) (compound_statement "{\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }" { (labeled_statement "LAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);" statement_identifier : (expression_statement "png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);" (call_expression "png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX)" identifier (argument_list "(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX)" ( identifier , (string_literal ""iTXt: invalid compression"" " string_content ") , identifier , identifier ))) ;)) })) }) (else_clause "else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" else (if_statement "if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" if (parenthesized_expression "(param_2 != 1)" ( (binary_expression "param_2 != 1" identifier != number_literal) )) (compound_statement "{\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" { (if_statement "if (param_2 != 2) goto LAB_0003c9ae;" if (parenthesized_expression "(param_2 != 2)" ( (binary_expression "param_2 != 2" identifier != number_literal) )) (goto_statement "goto LAB_0003c9ae;" goto statement_identifier ;)) (goto_statement "goto LAB_0003c58f;" goto statement_identifier ;) })))) (expression_statement "bVar1 = false;" (assignment_expression "bVar1 = false" identifier = false) ;) (expression_statement "auStack_71[iVar2] = 0;" (assignment_expression "auStack_71[iVar2] = 0" (subscript_expression "auStack_71[iVar2]" identifier [ identifier ]) = number_literal) ;) }))) (expression_statement "auStack_71[iVar2 + 1] = 0;" (assignment_expression "auStack_71[iVar2 + 1] = 0" (subscript_expression "auStack_71[iVar2 + 1]" identifier [ (binary_expression "iVar2 + 1" identifier + number_literal) ]) = number_literal) ;) (expression_statement "iVar2 = iVar2 + 3;" (assignment_expression "iVar2 = iVar2 + 3" identifier = (binary_expression "iVar2 + 3" identifier + number_literal)) ;) (if_statement "if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" if (parenthesized_expression "(param_4 == (char *)0x0)" ( (binary_expression "param_4 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    local_4a4 = "";\n    local_4a8 = 1;\n  }" { (expression_statement "local_4a4 = "";" (assignment_expression "local_4a4 = """ identifier = (string_literal """" " ")) ;) (expression_statement "local_4a8 = 1;" (assignment_expression "local_4a8 = 1" identifier = number_literal) ;) }) (else_clause "else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" else (compound_statement "{\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" { (expression_statement "sVar3 = strlen(param_4);" (assignment_expression "sVar3 = strlen(param_4)" identifier = (call_expression "strlen(param_4)" identifier (argument_list "(param_4)" ( identifier )))) ;) (expression_statement "local_4a8 = sVar3 + 1;" (assignment_expression "local_4a8 = sVar3 + 1" identifier = (binary_expression "sVar3 + 1" identifier + number_literal)) ;) }))) (if_statement "if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" if (parenthesized_expression "(param_5 == (char *)0x0)" ( (binary_expression "param_5 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    local_4a0 = "";\n    local_498 = 1;\n  }" { (expression_statement "local_4a0 = "";" (assignment_expression "local_4a0 = """ identifier = (string_literal """" " ")) ;) (expression_statement "local_498 = 1;" (assignment_expression "local_498 = 1" identifier = number_literal) ;) }) (else_clause "else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" else (compound_statement "{\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" { (expression_statement "sVar3 = strlen(param_5);" (assignment_expression "sVar3 = strlen(param_5)" identifier = (call_expression "strlen(param_5)" identifier (argument_list "(param_5)" ( identifier )))) ;) (expression_statement "local_498 = sVar3 + 1;" (assignment_expression "local_498 = sVar3 + 1" identifier = (binary_expression "sVar3 + 1" identifier + number_literal)) ;) }))) (if_statement "if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }" if (parenthesized_expression "(param_6 == (char *)0x0)" ( (binary_expression "param_6 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar4 = 0;\n    param_6 = "";\n  }" { (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (expression_statement "param_6 = "";" (assignment_expression "param_6 = """ identifier = (string_literal """" " ")) ;) }) (else_clause "else {\n    uVar4 = strlen(param_6);\n  }" else (compound_statement "{\n    uVar4 = strlen(param_6);\n  }" { (expression_statement "uVar4 = strlen(param_6);" (assignment_expression "uVar4 = strlen(param_6)" identifier = (call_expression "strlen(param_6)" identifier (argument_list "(param_6)" ( identifier )))) ;) }))) (expression_statement "iVar6 = 0x7fffffff;" (assignment_expression "iVar6 = 0x7fffffff" identifier = number_literal) ;) (if_statement "if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }" if (parenthesized_expression "((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2)))" ( (binary_expression "(local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))" (parenthesized_expression "(local_4a8 <= 0x7fffffffU - iVar2)" ( (binary_expression "local_4a8 <= 0x7fffffffU - iVar2" identifier <= (binary_expression "0x7fffffffU - iVar2" number_literal - identifier)) )) && (parenthesized_expression "(local_498 <= 0x7fffffff - (local_4a8 + iVar2))" ( (binary_expression "local_498 <= 0x7fffffff - (local_4a8 + iVar2)" identifier <= (binary_expression "0x7fffffff - (local_4a8 + iVar2)" number_literal - (parenthesized_expression "(local_4a8 + iVar2)" ( (binary_expression "local_4a8 + iVar2" identifier + identifier) )))) ))) )) (compound_statement "{\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }" { (expression_statement "iVar6 = local_4a8 + iVar2 + local_498;" (assignment_expression "iVar6 = local_4a8 + iVar2 + local_498" identifier = (binary_expression "local_4a8 + iVar2 + local_498" (binary_expression "local_4a8 + iVar2" identifier + identifier) + identifier)) ;) })) (if_statement "if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" if (parenthesized_expression "(bVar1)" ( identifier )) (compound_statement "{\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }" { (expression_statement "iVar5 = FUN_0003a060();" (assignment_expression "iVar5 = FUN_0003a060()" identifier = (call_expression "FUN_0003a060()" identifier (argument_list "()" ( )))) ;) (if_statement "if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }" if (parenthesized_expression "((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0))" ( (binary_expression "(iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)" (parenthesized_expression "(iVar5 != 0)" ( (binary_expression "iVar5 != 0" identifier != number_literal) )) || (parenthesized_expression "(iVar5 = FUN_0003a340(), iVar5 != 0)" ( (comma_expression "iVar5 = FUN_0003a340(), iVar5 != 0" (assignment_expression "iVar5 = FUN_0003a340()" identifier = (call_expression "FUN_0003a340()" identifier (argument_list "()" ( )))) , (binary_expression "iVar5 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }" { (expression_statement "png_error(param_1,*(undefined4 *)(param_1 + 0xf8));" (call_expression "png_error(param_1,*(undefined4 *)(param_1 + 0xf8))" identifier (argument_list "(param_1,*(undefined4 *)(param_1 + 0xf8))" ( identifier , (pointer_expression "*(undefined4 *)(param_1 + 0xf8)" * (cast_expression "(undefined4 *)(param_1 + 0xf8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xf8)" ( (binary_expression "param_1 + 0xf8" identifier + number_literal) )))) ))) ;) })) (if_statement "if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" if (parenthesized_expression "(param_1 == 0)" ( (binary_expression "param_1 == 0" identifier == number_literal) )) (compound_statement "{\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }" { (expression_statement "png_write_chunk_data(0,&local_72,iVar2);" (call_expression "png_write_chunk_data(0,&local_72,iVar2)" identifier (argument_list "(0,&local_72,iVar2)" ( number_literal , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(0,local_4a4,local_4a8)" identifier (argument_list "(0,local_4a4,local_4a8)" ( number_literal , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a0,local_498);" (call_expression "png_write_chunk_data(0,local_4a0,local_498)" identifier (argument_list "(0,local_4a0,local_498)" ( number_literal , identifier , identifier ))) ;) }) (else_clause "else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" else (compound_statement "{\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" { (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x22;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x22" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_save_uint_32(local_7a,iVar6);" (call_expression "png_save_uint_32(local_7a,iVar6)" identifier (argument_list "(local_7a,iVar6)" ( identifier , identifier ))) ;) (expression_statement "png_save_uint_32(local_76,0x69545874);" (call_expression "png_save_uint_32(local_76,0x69545874)" identifier (argument_list "(local_76,0x69545874)" ( identifier , number_literal ))) ;) (expression_statement "FUN_000360c0(param_1,local_7a,8);" (call_expression "FUN_000360c0(param_1,local_7a,8)" identifier (argument_list "(param_1,local_7a,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x178) = 0x69545874;" (assignment_expression "*(undefined4 *)(param_1 + 0x178) = 0x69545874" (pointer_expression "*(undefined4 *)(param_1 + 0x178)" * (cast_expression "(undefined4 *)(param_1 + 0x178)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x178)" ( (binary_expression "param_1 + 0x178" identifier + number_literal) )))) = number_literal) ;) (expression_statement "FUN_00014f90(param_1);" (call_expression "FUN_00014f90(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (expression_statement "FUN_00014fc0(param_1,local_76,4);" (call_expression "FUN_00014fc0(param_1,local_76,4)" identifier (argument_list "(param_1,local_76,4)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x42;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x42" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_write_chunk_data(param_1,&local_72,iVar2);" (call_expression "png_write_chunk_data(param_1,&local_72,iVar2)" identifier (argument_list "(param_1,&local_72,iVar2)" ( identifier , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(param_1,local_4a4,local_4a8)" identifier (argument_list "(param_1,local_4a4,local_4a8)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a0,local_498);" (call_expression "png_write_chunk_data(param_1,local_4a0,local_498)" identifier (argument_list "(param_1,local_4a0,local_498)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_data(param_1,local_47c,0);" (call_expression "png_write_chunk_data(param_1,local_47c,0)" identifier (argument_list "(param_1,local_47c,0)" ( identifier , identifier , number_literal ))) ;) }) (else_clause "else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" else (compound_statement "{\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" { (if_statement "if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }" if (parenthesized_expression "(0x7fffffffU - iVar6 < uVar4)" ( (binary_expression "0x7fffffffU - iVar6 < uVar4" (binary_expression "0x7fffffffU - iVar6" number_literal - identifier) < identifier) )) (compound_statement "{\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }" { (expression_statement "png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);" (call_expression "png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4)" identifier (argument_list "(param_1,"iTXt: uncompressed text too long",uVar4,uVar4)" ( identifier , (string_literal ""iTXt: uncompressed text too long"" " string_content ") , identifier , identifier ))) ;) })) (if_statement "if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" if (parenthesized_expression "(param_1 == 0)" ( (binary_expression "param_1 == 0" identifier == number_literal) )) (compound_statement "{\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }" { (expression_statement "png_write_chunk_data(0,&local_72,iVar2);" (call_expression "png_write_chunk_data(0,&local_72,iVar2)" identifier (argument_list "(0,&local_72,iVar2)" ( number_literal , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(0,local_4a4,local_4a8)" identifier (argument_list "(0,local_4a4,local_4a8)" ( number_literal , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(0,local_4a0,local_498);" (call_expression "png_write_chunk_data(0,local_4a0,local_498)" identifier (argument_list "(0,local_4a0,local_498)" ( number_literal , identifier , identifier ))) ;) }) (else_clause "else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" else (compound_statement "{\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" { (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x22;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x22" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_save_uint_32(local_7a,uVar4 + iVar6);" (call_expression "png_save_uint_32(local_7a,uVar4 + iVar6)" identifier (argument_list "(local_7a,uVar4 + iVar6)" ( identifier , (binary_expression "uVar4 + iVar6" identifier + identifier) ))) ;) (expression_statement "png_save_uint_32(local_76,0x69545874);" (call_expression "png_save_uint_32(local_76,0x69545874)" identifier (argument_list "(local_76,0x69545874)" ( identifier , number_literal ))) ;) (expression_statement "FUN_000360c0(param_1,local_7a,8);" (call_expression "FUN_000360c0(param_1,local_7a,8)" identifier (argument_list "(param_1,local_7a,8)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x178) = 0x69545874;" (assignment_expression "*(undefined4 *)(param_1 + 0x178) = 0x69545874" (pointer_expression "*(undefined4 *)(param_1 + 0x178)" * (cast_expression "(undefined4 *)(param_1 + 0x178)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x178)" ( (binary_expression "param_1 + 0x178" identifier + number_literal) )))) = number_literal) ;) (expression_statement "FUN_00014f90(param_1);" (call_expression "FUN_00014f90(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (expression_statement "FUN_00014fc0(param_1,local_76,4);" (call_expression "FUN_00014fc0(param_1,local_76,4)" identifier (argument_list "(param_1,local_76,4)" ( identifier , identifier , number_literal ))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x42;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x42" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" * (cast_expression "(undefined4 *)(param_1 + 0x32c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x32c)" ( (binary_expression "param_1 + 0x32c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "png_write_chunk_data(param_1,&local_72,iVar2);" (call_expression "png_write_chunk_data(param_1,&local_72,iVar2)" identifier (argument_list "(param_1,&local_72,iVar2)" ( identifier , (pointer_expression "&local_72" & identifier) , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(param_1,local_4a4,local_4a8)" identifier (argument_list "(param_1,local_4a4,local_4a8)" ( identifier , identifier , identifier ))) ;) (expression_statement "png_write_chunk_data(param_1,local_4a0,local_498);" (call_expression "png_write_chunk_data(param_1,local_4a0,local_498)" identifier (argument_list "(param_1,local_4a0,local_498)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_data(param_1,param_6,uVar4);" (call_expression "png_write_chunk_data(param_1,param_6,uVar4)" identifier (argument_list "(param_1,param_6,uVar4)" ( identifier , identifier , identifier ))) ;) }))) (expression_statement "png_write_chunk_end(param_1);" (call_expression "png_write_chunk_end(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }" if (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    \n    FUN_0003f340();\n  }" { (expression_statement "FUN_0003f340();" (call_expression "FUN_0003f340()" identifier (argument_list "()" ( ))) ;) })) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * 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 ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (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 + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , (pointer_expression & IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") , IDENT , IDENT ))) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = BOOL) ;)) (expression_statement (assignment_expression (subscript_expression IDENT [ IDENT ]) = LIT) ;) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") , IDENT , IDENT ))) ;)) })) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (goto_statement goto statement_identifier ;)) (goto_statement goto statement_identifier ;) })))) (expression_statement (assignment_expression IDENT = BOOL) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ IDENT ]) = LIT) ;) }))) (expression_statement (assignment_expression (subscript_expression IDENT [ (binary_expression IDENT + LIT) ]) = LIT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (string_literal " ")) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (string_literal " ")) ;) (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (string_literal " ")) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) }))) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT <= (binary_expression LIT - IDENT)) )) && (parenthesized_expression ( (binary_expression IDENT <= (binary_expression LIT - (parenthesized_expression ( (binary_expression IDENT + IDENT) )))) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (binary_expression IDENT + IDENT) + IDENT)) ;) })) (if_statement if (parenthesized_expression ( IDENT )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) , (binary_expression IDENT != LIT)) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( LIT , (pointer_expression & IDENT) , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( LIT , IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( LIT , IDENT , IDENT ))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , LIT ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , LIT ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , LIT ))) ;) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (binary_expression LIT - IDENT) < IDENT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (string_literal " string_content ") , IDENT , IDENT ))) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( LIT , (pointer_expression & IDENT) , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( LIT , IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( LIT , IDENT , IDENT ))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , (binary_expression IDENT + IDENT) ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , LIT ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , LIT ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) }))) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (return_statement return ;) })))
(function_definition "void FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)\n\n{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }\n  return;\n}" (primitive_type "void") (function_declarator "FUN_0003c500(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)" (identifier "FUN_0003c500") (parameter_list "(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,\n                 char *param_6)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) (, ",") (parameter_declaration "undefined4 param_3" (type_identifier "undefined4") (identifier "param_3")) (, ",") (parameter_declaration "char *param_4" (primitive_type "char") (pointer_declarator "*param_4" (* "*") (identifier "param_4"))) (, ",") (parameter_declaration "char *param_5" (primitive_type "char") (pointer_declarator "*param_5" (* "*") (identifier "param_5"))) (, ",") (parameter_declaration "char *param_6" (primitive_type "char") (pointer_declarator "*param_6" (* "*") (identifier "param_6"))) () ")"))) (compound_statement "{\n  bool bVar1;\n  int iVar2;\n  size_t sVar3;\n  uint uVar4;\n  int iVar5;\n  undefined4 extraout_ECX;\n  int iVar6;\n  int in_GS_OFFSET;\n  uint local_4a8;\n  char *local_4a4;\n  char *local_4a0;\n  uint local_498;\n  undefined1 local_47c [1026];\n  undefined1 local_7a [4];\n  undefined1 local_76 [4];\n  undefined1 local_72;\n  undefined1 auStack_71 [81];\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x3c509;\n  local_4a4 = param_4;\n  local_4a0 = param_5;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  iVar2 = FUN_00035490(param_1,param_3,&local_72);\n  if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }\n  if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }\n  auStack_71[iVar2 + 1] = 0;\n  iVar2 = iVar2 + 3;\n  if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }\n  if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }\n  if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }\n  iVar6 = 0x7fffffff;\n  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }\n  if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }\n  png_write_chunk_end(param_1);\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }\n  return;\n}" ({ "{") (declaration "bool bVar1;" (primitive_type "bool") (identifier "bVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "size_t sVar3;" (primitive_type "size_t") (identifier "sVar3") (; ";")) (declaration "uint uVar4;" (type_identifier "uint") (identifier "uVar4") (; ";")) (declaration "int iVar5;" (primitive_type "int") (identifier "iVar5") (; ";")) (declaration "undefined4 extraout_ECX;" (type_identifier "undefined4") (identifier "extraout_ECX") (; ";")) (declaration "int iVar6;" (primitive_type "int") (identifier "iVar6") (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "uint local_4a8;" (type_identifier "uint") (identifier "local_4a8") (; ";")) (declaration "char *local_4a4;" (primitive_type "char") (pointer_declarator "*local_4a4" (* "*") (identifier "local_4a4")) (; ";")) (declaration "char *local_4a0;" (primitive_type "char") (pointer_declarator "*local_4a0" (* "*") (identifier "local_4a0")) (; ";")) (declaration "uint local_498;" (type_identifier "uint") (identifier "local_498") (; ";")) (declaration "undefined1 local_47c [1026];" (type_identifier "undefined1") (array_declarator "local_47c [1026]" (identifier "local_47c") ([ "[") (number_literal "1026") (] "]")) (; ";")) (declaration "undefined1 local_7a [4];" (type_identifier "undefined1") (array_declarator "local_7a [4]" (identifier "local_7a") ([ "[") (number_literal "4") (] "]")) (; ";")) (declaration "undefined1 local_76 [4];" (type_identifier "undefined1") (array_declarator "local_76 [4]" (identifier "local_76") ([ "[") (number_literal "4") (] "]")) (; ";")) (declaration "undefined1 local_72;" (type_identifier "undefined1") (identifier "local_72") (; ";")) (declaration "undefined1 auStack_71 [81];" (type_identifier "undefined1") (array_declarator "auStack_71 [81]" (identifier "auStack_71") ([ "[") (number_literal "81") (] "]")) (; ";")) (declaration "int local_20;" (primitive_type "int") (identifier "local_20") (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x3c509;" (assignment_expression "uStack_14 = 0x3c509" (identifier "uStack_14") (= "=") (number_literal "0x3c509")) (; ";")) (expression_statement "local_4a4 = param_4;" (assignment_expression "local_4a4 = param_4" (identifier "local_4a4") (= "=") (identifier "param_4")) (; ";")) (expression_statement "local_4a0 = param_5;" (assignment_expression "local_4a0 = param_5" (identifier "local_4a0") (= "=") (identifier "param_5")) (; ";")) (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 "iVar2 = FUN_00035490(param_1,param_3,&local_72);" (assignment_expression "iVar2 = FUN_00035490(param_1,param_3,&local_72)" (identifier "iVar2") (= "=") (call_expression "FUN_00035490(param_1,param_3,&local_72)" (identifier "FUN_00035490") (argument_list "(param_1,param_3,&local_72)" (( "(") (identifier "param_1") (, ",") (identifier "param_3") (, ",") (pointer_expression "&local_72" (& "&") (identifier "local_72")) () ")")))) (; ";")) (if_statement "if (iVar2 == 0) {\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }" (if "if") (parenthesized_expression "(iVar2 == 0)" (( "(") (binary_expression "iVar2 == 0" (identifier "iVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n                    \n    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);\n  }" ({ "{") (expression_statement "png_error(param_1,"iTXt: invalid keyword",param_6,param_6);" (call_expression "png_error(param_1,"iTXt: invalid keyword",param_6,param_6)" (identifier "png_error") (argument_list "(param_1,"iTXt: invalid keyword",param_6,param_6)" (( "(") (identifier "param_1") (, ",") (string_literal ""iTXt: invalid keyword"" (" """) (string_content "iTXt: invalid keyword") (" """)) (, ",") (identifier "param_6") (, ",") (identifier "param_6") () ")"))) (; ";")) (} "}"))) (if_statement "if (param_2 == 0) {\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }\n  else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" (if "if") (parenthesized_expression "(param_2 == 0)" (( "(") (binary_expression "param_2 == 0" (identifier "param_2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\nLAB_0003c58f:\n    bVar1 = true;\n    auStack_71[iVar2] = 1;\n  }" ({ "{") (labeled_statement "LAB_0003c58f:\n    bVar1 = true;" (statement_identifier "LAB_0003c58f") (: ":") (expression_statement "bVar1 = true;" (assignment_expression "bVar1 = true" (identifier "bVar1") (= "=") (true "true")) (; ";"))) (expression_statement "auStack_71[iVar2] = 1;" (assignment_expression "auStack_71[iVar2] = 1" (subscript_expression "auStack_71[iVar2]" (identifier "auStack_71") ([ "[") (identifier "iVar2") (] "]")) (= "=") (number_literal "1")) (; ";")) (} "}")) (else_clause "else {\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" (else "else") (compound_statement "{\n    if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }\n    bVar1 = false;\n    auStack_71[iVar2] = 0;\n  }" ({ "{") (if_statement "if (param_2 < 1) {\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }\n    else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" (if "if") (parenthesized_expression "(param_2 < 1)" (( "(") (binary_expression "param_2 < 1" (identifier "param_2") (< "<") (number_literal "1")) () ")")) (compound_statement "{\n      if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }\n    }" ({ "{") (if_statement "if (param_2 != -1) {\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }" (if "if") (parenthesized_expression "(param_2 != -1)" (( "(") (binary_expression "param_2 != -1" (identifier "param_2") (!= "!=") (number_literal "-1")) () ")")) (compound_statement "{\nLAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);\n      }" ({ "{") (labeled_statement "LAB_0003c9ae:\n                    \n        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);" (statement_identifier "LAB_0003c9ae") (: ":") (expression_statement "png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);" (call_expression "png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX)" (identifier "png_error") (argument_list "(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX)" (( "(") (identifier "param_1") (, ",") (string_literal ""iTXt: invalid compression"" (" """) (string_content "iTXt: invalid compression") (" """)) (, ",") (identifier "extraout_ECX") (, ",") (identifier "extraout_ECX") () ")"))) (; ";"))) (} "}"))) (} "}")) (else_clause "else if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" (else "else") (if_statement "if (param_2 != 1) {\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" (if "if") (parenthesized_expression "(param_2 != 1)" (( "(") (binary_expression "param_2 != 1" (identifier "param_2") (!= "!=") (number_literal "1")) () ")")) (compound_statement "{\n      if (param_2 != 2) goto LAB_0003c9ae;\n      goto LAB_0003c58f;\n    }" ({ "{") (if_statement "if (param_2 != 2) goto LAB_0003c9ae;" (if "if") (parenthesized_expression "(param_2 != 2)" (( "(") (binary_expression "param_2 != 2" (identifier "param_2") (!= "!=") (number_literal "2")) () ")")) (goto_statement "goto LAB_0003c9ae;" (goto "goto") (statement_identifier "LAB_0003c9ae") (; ";"))) (goto_statement "goto LAB_0003c58f;" (goto "goto") (statement_identifier "LAB_0003c58f") (; ";")) (} "}"))))) (expression_statement "bVar1 = false;" (assignment_expression "bVar1 = false" (identifier "bVar1") (= "=") (false "false")) (; ";")) (expression_statement "auStack_71[iVar2] = 0;" (assignment_expression "auStack_71[iVar2] = 0" (subscript_expression "auStack_71[iVar2]" (identifier "auStack_71") ([ "[") (identifier "iVar2") (] "]")) (= "=") (number_literal "0")) (; ";")) (} "}")))) (expression_statement "auStack_71[iVar2 + 1] = 0;" (assignment_expression "auStack_71[iVar2 + 1] = 0" (subscript_expression "auStack_71[iVar2 + 1]" (identifier "auStack_71") ([ "[") (binary_expression "iVar2 + 1" (identifier "iVar2") (+ "+") (number_literal "1")) (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "iVar2 = iVar2 + 3;" (assignment_expression "iVar2 = iVar2 + 3" (identifier "iVar2") (= "=") (binary_expression "iVar2 + 3" (identifier "iVar2") (+ "+") (number_literal "3"))) (; ";")) (if_statement "if (param_4 == (char *)0x0) {\n    local_4a4 = "";\n    local_4a8 = 1;\n  }\n  else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" (if "if") (parenthesized_expression "(param_4 == (char *)0x0)" (( "(") (binary_expression "param_4 == (char *)0x0" (identifier "param_4") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    local_4a4 = "";\n    local_4a8 = 1;\n  }" ({ "{") (expression_statement "local_4a4 = "";" (assignment_expression "local_4a4 = """ (identifier "local_4a4") (= "=") (string_literal """" (" """) (" """))) (; ";")) (expression_statement "local_4a8 = 1;" (assignment_expression "local_4a8 = 1" (identifier "local_4a8") (= "=") (number_literal "1")) (; ";")) (} "}")) (else_clause "else {\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" (else "else") (compound_statement "{\n    sVar3 = strlen(param_4);\n    local_4a8 = sVar3 + 1;\n  }" ({ "{") (expression_statement "sVar3 = strlen(param_4);" (assignment_expression "sVar3 = strlen(param_4)" (identifier "sVar3") (= "=") (call_expression "strlen(param_4)" (identifier "strlen") (argument_list "(param_4)" (( "(") (identifier "param_4") () ")")))) (; ";")) (expression_statement "local_4a8 = sVar3 + 1;" (assignment_expression "local_4a8 = sVar3 + 1" (identifier "local_4a8") (= "=") (binary_expression "sVar3 + 1" (identifier "sVar3") (+ "+") (number_literal "1"))) (; ";")) (} "}")))) (if_statement "if (param_5 == (char *)0x0) {\n    local_4a0 = "";\n    local_498 = 1;\n  }\n  else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" (if "if") (parenthesized_expression "(param_5 == (char *)0x0)" (( "(") (binary_expression "param_5 == (char *)0x0" (identifier "param_5") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    local_4a0 = "";\n    local_498 = 1;\n  }" ({ "{") (expression_statement "local_4a0 = "";" (assignment_expression "local_4a0 = """ (identifier "local_4a0") (= "=") (string_literal """" (" """) (" """))) (; ";")) (expression_statement "local_498 = 1;" (assignment_expression "local_498 = 1" (identifier "local_498") (= "=") (number_literal "1")) (; ";")) (} "}")) (else_clause "else {\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" (else "else") (compound_statement "{\n    sVar3 = strlen(param_5);\n    local_498 = sVar3 + 1;\n  }" ({ "{") (expression_statement "sVar3 = strlen(param_5);" (assignment_expression "sVar3 = strlen(param_5)" (identifier "sVar3") (= "=") (call_expression "strlen(param_5)" (identifier "strlen") (argument_list "(param_5)" (( "(") (identifier "param_5") () ")")))) (; ";")) (expression_statement "local_498 = sVar3 + 1;" (assignment_expression "local_498 = sVar3 + 1" (identifier "local_498") (= "=") (binary_expression "sVar3 + 1" (identifier "sVar3") (+ "+") (number_literal "1"))) (; ";")) (} "}")))) (if_statement "if (param_6 == (char *)0x0) {\n    uVar4 = 0;\n    param_6 = "";\n  }\n  else {\n    uVar4 = strlen(param_6);\n  }" (if "if") (parenthesized_expression "(param_6 == (char *)0x0)" (( "(") (binary_expression "param_6 == (char *)0x0" (identifier "param_6") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    uVar4 = 0;\n    param_6 = "";\n  }" ({ "{") (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" (identifier "uVar4") (= "=") (number_literal "0")) (; ";")) (expression_statement "param_6 = "";" (assignment_expression "param_6 = """ (identifier "param_6") (= "=") (string_literal """" (" """) (" """))) (; ";")) (} "}")) (else_clause "else {\n    uVar4 = strlen(param_6);\n  }" (else "else") (compound_statement "{\n    uVar4 = strlen(param_6);\n  }" ({ "{") (expression_statement "uVar4 = strlen(param_6);" (assignment_expression "uVar4 = strlen(param_6)" (identifier "uVar4") (= "=") (call_expression "strlen(param_6)" (identifier "strlen") (argument_list "(param_6)" (( "(") (identifier "param_6") () ")")))) (; ";")) (} "}")))) (expression_statement "iVar6 = 0x7fffffff;" (assignment_expression "iVar6 = 0x7fffffff" (identifier "iVar6") (= "=") (number_literal "0x7fffffff")) (; ";")) (if_statement "if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }" (if "if") (parenthesized_expression "((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2)))" (( "(") (binary_expression "(local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))" (parenthesized_expression "(local_4a8 <= 0x7fffffffU - iVar2)" (( "(") (binary_expression "local_4a8 <= 0x7fffffffU - iVar2" (identifier "local_4a8") (<= "<=") (binary_expression "0x7fffffffU - iVar2" (number_literal "0x7fffffffU") (- "-") (identifier "iVar2"))) () ")")) (&& "&&") (parenthesized_expression "(local_498 <= 0x7fffffff - (local_4a8 + iVar2))" (( "(") (binary_expression "local_498 <= 0x7fffffff - (local_4a8 + iVar2)" (identifier "local_498") (<= "<=") (binary_expression "0x7fffffff - (local_4a8 + iVar2)" (number_literal "0x7fffffff") (- "-") (parenthesized_expression "(local_4a8 + iVar2)" (( "(") (binary_expression "local_4a8 + iVar2" (identifier "local_4a8") (+ "+") (identifier "iVar2")) () ")")))) () ")"))) () ")")) (compound_statement "{\n    iVar6 = local_4a8 + iVar2 + local_498;\n  }" ({ "{") (expression_statement "iVar6 = local_4a8 + iVar2 + local_498;" (assignment_expression "iVar6 = local_4a8 + iVar2 + local_498" (identifier "iVar6") (= "=") (binary_expression "local_4a8 + iVar2 + local_498" (binary_expression "local_4a8 + iVar2" (identifier "local_4a8") (+ "+") (identifier "iVar2")) (+ "+") (identifier "local_498"))) (; ";")) (} "}"))) (if_statement "if (bVar1) {\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }\n  else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" (if "if") (parenthesized_expression "(bVar1)" (( "(") (identifier "bVar1") () ")")) (compound_statement "{\n    iVar5 = FUN_0003a060();\n    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,local_47c,0);\n  }" ({ "{") (expression_statement "iVar5 = FUN_0003a060();" (assignment_expression "iVar5 = FUN_0003a060()" (identifier "iVar5") (= "=") (call_expression "FUN_0003a060()" (identifier "FUN_0003a060") (argument_list "()" (( "(") () ")")))) (; ";")) (if_statement "if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }" (if "if") (parenthesized_expression "((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0))" (( "(") (binary_expression "(iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)" (parenthesized_expression "(iVar5 != 0)" (( "(") (binary_expression "iVar5 != 0" (identifier "iVar5") (!= "!=") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "(iVar5 = FUN_0003a340(), iVar5 != 0)" (( "(") (comma_expression "iVar5 = FUN_0003a340(), iVar5 != 0" (assignment_expression "iVar5 = FUN_0003a340()" (identifier "iVar5") (= "=") (call_expression "FUN_0003a340()" (identifier "FUN_0003a340") (argument_list "()" (( "(") () ")")))) (, ",") (binary_expression "iVar5 != 0" (identifier "iVar5") (!= "!=") (number_literal "0"))) () ")"))) () ")")) (compound_statement "{\n                    \n      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));\n    }" ({ "{") (expression_statement "png_error(param_1,*(undefined4 *)(param_1 + 0xf8));" (call_expression "png_error(param_1,*(undefined4 *)(param_1 + 0xf8))" (identifier "png_error") (argument_list "(param_1,*(undefined4 *)(param_1 + 0xf8))" (( "(") (identifier "param_1") (, ",") (pointer_expression "*(undefined4 *)(param_1 + 0xf8)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0xf8)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xf8)" (( "(") (binary_expression "param_1 + 0xf8" (identifier "param_1") (+ "+") (number_literal "0xf8")) () ")")))) () ")"))) (; ";")) (} "}"))) (if_statement "if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" (if "if") (parenthesized_expression "(param_1 == 0)" (( "(") (binary_expression "param_1 == 0" (identifier "param_1") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }" ({ "{") (expression_statement "png_write_chunk_data(0,&local_72,iVar2);" (call_expression "png_write_chunk_data(0,&local_72,iVar2)" (identifier "png_write_chunk_data") (argument_list "(0,&local_72,iVar2)" (( "(") (number_literal "0") (, ",") (pointer_expression "&local_72" (& "&") (identifier "local_72")) (, ",") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(0,local_4a4,local_4a8)" (identifier "png_write_chunk_data") (argument_list "(0,local_4a4,local_4a8)" (( "(") (number_literal "0") (, ",") (identifier "local_4a4") (, ",") (identifier "local_4a8") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(0,local_4a0,local_498);" (call_expression "png_write_chunk_data(0,local_4a0,local_498)" (identifier "png_write_chunk_data") (argument_list "(0,local_4a0,local_498)" (( "(") (number_literal "0") (, ",") (identifier "local_4a0") (, ",") (identifier "local_498") () ")"))) (; ";")) (} "}")) (else_clause "else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" (else "else") (compound_statement "{\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" ({ "{") (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x22;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x22" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x32c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x32c)" (( "(") (binary_expression "param_1 + 0x32c" (identifier "param_1") (+ "+") (number_literal "0x32c")) () ")")))) (= "=") (number_literal "0x22")) (; ";")) (expression_statement "png_save_uint_32(local_7a,iVar6);" (call_expression "png_save_uint_32(local_7a,iVar6)" (identifier "png_save_uint_32") (argument_list "(local_7a,iVar6)" (( "(") (identifier "local_7a") (, ",") (identifier "iVar6") () ")"))) (; ";")) (expression_statement "png_save_uint_32(local_76,0x69545874);" (call_expression "png_save_uint_32(local_76,0x69545874)" (identifier "png_save_uint_32") (argument_list "(local_76,0x69545874)" (( "(") (identifier "local_76") (, ",") (number_literal "0x69545874") () ")"))) (; ";")) (expression_statement "FUN_000360c0(param_1,local_7a,8);" (call_expression "FUN_000360c0(param_1,local_7a,8)" (identifier "FUN_000360c0") (argument_list "(param_1,local_7a,8)" (( "(") (identifier "param_1") (, ",") (identifier "local_7a") (, ",") (number_literal "8") () ")"))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x178) = 0x69545874;" (assignment_expression "*(undefined4 *)(param_1 + 0x178) = 0x69545874" (pointer_expression "*(undefined4 *)(param_1 + 0x178)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x178)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x178)" (( "(") (binary_expression "param_1 + 0x178" (identifier "param_1") (+ "+") (number_literal "0x178")) () ")")))) (= "=") (number_literal "0x69545874")) (; ";")) (expression_statement "FUN_00014f90(param_1);" (call_expression "FUN_00014f90(param_1)" (identifier "FUN_00014f90") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (expression_statement "FUN_00014fc0(param_1,local_76,4);" (call_expression "FUN_00014fc0(param_1,local_76,4)" (identifier "FUN_00014fc0") (argument_list "(param_1,local_76,4)" (( "(") (identifier "param_1") (, ",") (identifier "local_76") (, ",") (number_literal "4") () ")"))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x42;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x42" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x32c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x32c)" (( "(") (binary_expression "param_1 + 0x32c" (identifier "param_1") (+ "+") (number_literal "0x32c")) () ")")))) (= "=") (number_literal "0x42")) (; ";")) (expression_statement "png_write_chunk_data(param_1,&local_72,iVar2);" (call_expression "png_write_chunk_data(param_1,&local_72,iVar2)" (identifier "png_write_chunk_data") (argument_list "(param_1,&local_72,iVar2)" (( "(") (identifier "param_1") (, ",") (pointer_expression "&local_72" (& "&") (identifier "local_72")) (, ",") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(param_1,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(param_1,local_4a4,local_4a8)" (identifier "png_write_chunk_data") (argument_list "(param_1,local_4a4,local_4a8)" (( "(") (identifier "param_1") (, ",") (identifier "local_4a4") (, ",") (identifier "local_4a8") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(param_1,local_4a0,local_498);" (call_expression "png_write_chunk_data(param_1,local_4a0,local_498)" (identifier "png_write_chunk_data") (argument_list "(param_1,local_4a0,local_498)" (( "(") (identifier "param_1") (, ",") (identifier "local_4a0") (, ",") (identifier "local_498") () ")"))) (; ";")) (} "}")))) (expression_statement "png_write_chunk_data(param_1,local_47c,0);" (call_expression "png_write_chunk_data(param_1,local_47c,0)" (identifier "png_write_chunk_data") (argument_list "(param_1,local_47c,0)" (( "(") (identifier "param_1") (, ",") (identifier "local_47c") (, ",") (number_literal "0") () ")"))) (; ";")) (} "}")) (else_clause "else {\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" (else "else") (compound_statement "{\n    if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }\n    if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }\n    png_write_chunk_data(param_1,param_6,uVar4);\n  }" ({ "{") (if_statement "if (0x7fffffffU - iVar6 < uVar4) {\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }" (if "if") (parenthesized_expression "(0x7fffffffU - iVar6 < uVar4)" (( "(") (binary_expression "0x7fffffffU - iVar6 < uVar4" (binary_expression "0x7fffffffU - iVar6" (number_literal "0x7fffffffU") (- "-") (identifier "iVar6")) (< "<") (identifier "uVar4")) () ")")) (compound_statement "{\n                    \n      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);\n    }" ({ "{") (expression_statement "png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);" (call_expression "png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4)" (identifier "png_error") (argument_list "(param_1,"iTXt: uncompressed text too long",uVar4,uVar4)" (( "(") (identifier "param_1") (, ",") (string_literal ""iTXt: uncompressed text too long"" (" """) (string_content "iTXt: uncompressed text too long") (" """)) (, ",") (identifier "uVar4") (, ",") (identifier "uVar4") () ")"))) (; ";")) (} "}"))) (if_statement "if (param_1 == 0) {\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }\n    else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" (if "if") (parenthesized_expression "(param_1 == 0)" (( "(") (binary_expression "param_1 == 0" (identifier "param_1") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      png_write_chunk_data(0,&local_72,iVar2);\n      png_write_chunk_data(0,local_4a4,local_4a8);\n      png_write_chunk_data(0,local_4a0,local_498);\n    }" ({ "{") (expression_statement "png_write_chunk_data(0,&local_72,iVar2);" (call_expression "png_write_chunk_data(0,&local_72,iVar2)" (identifier "png_write_chunk_data") (argument_list "(0,&local_72,iVar2)" (( "(") (number_literal "0") (, ",") (pointer_expression "&local_72" (& "&") (identifier "local_72")) (, ",") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(0,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(0,local_4a4,local_4a8)" (identifier "png_write_chunk_data") (argument_list "(0,local_4a4,local_4a8)" (( "(") (number_literal "0") (, ",") (identifier "local_4a4") (, ",") (identifier "local_4a8") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(0,local_4a0,local_498);" (call_expression "png_write_chunk_data(0,local_4a0,local_498)" (identifier "png_write_chunk_data") (argument_list "(0,local_4a0,local_498)" (( "(") (number_literal "0") (, ",") (identifier "local_4a0") (, ",") (identifier "local_498") () ")"))) (; ";")) (} "}")) (else_clause "else {\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" (else "else") (compound_statement "{\n      *(undefined4 *)(param_1 + 0x32c) = 0x22;\n      png_save_uint_32(local_7a,uVar4 + iVar6);\n      png_save_uint_32(local_76,0x69545874);\n      FUN_000360c0(param_1,local_7a,8);\n      *(undefined4 *)(param_1 + 0x178) = 0x69545874;\n      FUN_00014f90(param_1);\n      FUN_00014fc0(param_1,local_76,4);\n      *(undefined4 *)(param_1 + 0x32c) = 0x42;\n      png_write_chunk_data(param_1,&local_72,iVar2);\n      png_write_chunk_data(param_1,local_4a4,local_4a8);\n      png_write_chunk_data(param_1,local_4a0,local_498);\n    }" ({ "{") (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x22;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x22" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x32c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x32c)" (( "(") (binary_expression "param_1 + 0x32c" (identifier "param_1") (+ "+") (number_literal "0x32c")) () ")")))) (= "=") (number_literal "0x22")) (; ";")) (expression_statement "png_save_uint_32(local_7a,uVar4 + iVar6);" (call_expression "png_save_uint_32(local_7a,uVar4 + iVar6)" (identifier "png_save_uint_32") (argument_list "(local_7a,uVar4 + iVar6)" (( "(") (identifier "local_7a") (, ",") (binary_expression "uVar4 + iVar6" (identifier "uVar4") (+ "+") (identifier "iVar6")) () ")"))) (; ";")) (expression_statement "png_save_uint_32(local_76,0x69545874);" (call_expression "png_save_uint_32(local_76,0x69545874)" (identifier "png_save_uint_32") (argument_list "(local_76,0x69545874)" (( "(") (identifier "local_76") (, ",") (number_literal "0x69545874") () ")"))) (; ";")) (expression_statement "FUN_000360c0(param_1,local_7a,8);" (call_expression "FUN_000360c0(param_1,local_7a,8)" (identifier "FUN_000360c0") (argument_list "(param_1,local_7a,8)" (( "(") (identifier "param_1") (, ",") (identifier "local_7a") (, ",") (number_literal "8") () ")"))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x178) = 0x69545874;" (assignment_expression "*(undefined4 *)(param_1 + 0x178) = 0x69545874" (pointer_expression "*(undefined4 *)(param_1 + 0x178)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x178)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x178)" (( "(") (binary_expression "param_1 + 0x178" (identifier "param_1") (+ "+") (number_literal "0x178")) () ")")))) (= "=") (number_literal "0x69545874")) (; ";")) (expression_statement "FUN_00014f90(param_1);" (call_expression "FUN_00014f90(param_1)" (identifier "FUN_00014f90") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (expression_statement "FUN_00014fc0(param_1,local_76,4);" (call_expression "FUN_00014fc0(param_1,local_76,4)" (identifier "FUN_00014fc0") (argument_list "(param_1,local_76,4)" (( "(") (identifier "param_1") (, ",") (identifier "local_76") (, ",") (number_literal "4") () ")"))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x32c) = 0x42;" (assignment_expression "*(undefined4 *)(param_1 + 0x32c) = 0x42" (pointer_expression "*(undefined4 *)(param_1 + 0x32c)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x32c)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x32c)" (( "(") (binary_expression "param_1 + 0x32c" (identifier "param_1") (+ "+") (number_literal "0x32c")) () ")")))) (= "=") (number_literal "0x42")) (; ";")) (expression_statement "png_write_chunk_data(param_1,&local_72,iVar2);" (call_expression "png_write_chunk_data(param_1,&local_72,iVar2)" (identifier "png_write_chunk_data") (argument_list "(param_1,&local_72,iVar2)" (( "(") (identifier "param_1") (, ",") (pointer_expression "&local_72" (& "&") (identifier "local_72")) (, ",") (identifier "iVar2") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(param_1,local_4a4,local_4a8);" (call_expression "png_write_chunk_data(param_1,local_4a4,local_4a8)" (identifier "png_write_chunk_data") (argument_list "(param_1,local_4a4,local_4a8)" (( "(") (identifier "param_1") (, ",") (identifier "local_4a4") (, ",") (identifier "local_4a8") () ")"))) (; ";")) (expression_statement "png_write_chunk_data(param_1,local_4a0,local_498);" (call_expression "png_write_chunk_data(param_1,local_4a0,local_498)" (identifier "png_write_chunk_data") (argument_list "(param_1,local_4a0,local_498)" (( "(") (identifier "param_1") (, ",") (identifier "local_4a0") (, ",") (identifier "local_498") () ")"))) (; ";")) (} "}")))) (expression_statement "png_write_chunk_data(param_1,param_6,uVar4);" (call_expression "png_write_chunk_data(param_1,param_6,uVar4)" (identifier "png_write_chunk_data") (argument_list "(param_1,param_6,uVar4)" (( "(") (identifier "param_1") (, ",") (identifier "param_6") (, ",") (identifier "uVar4") () ")"))) (; ";")) (} "}")))) (expression_statement "png_write_chunk_end(param_1);" (call_expression "png_write_chunk_end(param_1)" (identifier "png_write_chunk_end") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0003f340();\n  }" (if "if") (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" (( "(") (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (!= "!=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n                    \n    FUN_0003f340();\n  }" ({ "{") (expression_statement "FUN_0003f340();" (call_expression "FUN_0003f340()" (identifier "FUN_0003f340") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (return_statement "return;" (return "return") (; ";")) (} "}")))

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

void function_1(type_1 var_18,int var_5,type_2 key,type_2 var_6,
                   type_2 var_9,type_2 var_10)

{
  int var_28;
  bool bVar2;
  type_3 var_3;
  size_t var_12;
  size_t var_8;
  int var_15;
  type_4 *data;
  type_5 *comp_00;
  type_6 var_25;
  type_7 var_26;
  int var_1;
  type_3 in_stack_fffffb54;
  type_6 var_11;
  type_8 local_4a4;
  type_8 local_4a0;
  type_6 var_13;
  type_5 var_17;
  type_4 var_21 [8];
  type_4 new_key [82];
  
  local_4a4 = (type_8)var_6;
  local_4a0 = (type_8)var_9;
  var_28 = *(int *)(var_1 + 0x14);
  var_3 = var_2(var_18,key,new_key);
  if (var_3 == 0) {
                    /* WARNING: Subroutine does not return */
    var_4(var_18,"iTXt: invalid keyword");
  }
  if (var_5 == 0) {
LAB_0003c58f:
    bVar2 = true;
    new_key[var_3 + 1] = '\x01';
  }
  else {
    if (var_5 < 1) {
      if (var_5 != -1) {
LAB_0003c9ae:
                    /* WARNING: Subroutine does not return */
        var_4(var_18,"iTXt: invalid compression");
      }
    }
    else if (var_5 != 1) {
      if (var_5 != 2) goto LAB_0003c9ae;
      goto LAB_0003c58f;
    }
    bVar2 = false;
    new_key[var_3 + 1] = '\0';
  }
  new_key[var_3 + 2] = '\0';
  var_12 = var_3 + 3;
  if (var_6 == (type_2)0x0) {
    local_4a4 = "";
    var_11 = 1;
  }
  else {
    var_8 = var_7(var_6);
    var_11 = var_8 + 1;
  }
  if (var_9 == (type_2)0x0) {
    local_4a0 = "";
    var_13 = 1;
  }
  else {
    var_8 = var_7(var_9);
    var_13 = var_8 + 1;
  }
  if (var_10 == (type_2)0x0) {
    var_17.input_len = 0;
    var_10 = "";
  }
  else {
    var_17.input_len = var_7(var_10);
  }
  comp_00 = (type_5 *)0x7fffffff;
  if ((var_11 <= 0x7fffffff - var_12) && (var_13 <= 0x7fffffff - (var_11 + var_12))) {
    comp_00 = (type_5 *)(var_11 + var_12 + var_13);
  }
  var_17.output_len = 0;
  var_17.input = (type_8)var_10;
  if (bVar2) {
    var_15 = var_14(var_18,0x69545874,var_17.input_len);
    if ((var_15 != 0) ||
       (var_15 = var_16(var_18,(type_3)&var_17,comp_00,in_stack_fffffb54), var_15 != 0)
       ) {
                    /* WARNING: Subroutine does not return */
      var_4(var_18,(var_18->zstream).msg);
    }
    if (var_18 == (type_1)0x0) {
      var_19((type_1)0x0,new_key,var_12);
      var_19((type_1)0x0,local_4a4,var_11);
      var_19((type_1)0x0,local_4a0,var_13);
    }
    else {
      var_18->io_state = 0x22;
      var_20(var_21,(type_3)(comp_00->output + (var_17.output_len - 0xc)));
      var_20(var_21 + 4,0x69545874);
      var_22(var_18,var_21,8);
      var_18->chunk_name = 0x69545874;
      var_23(var_18);
      var_24(var_18,var_21 + 4,4);
      var_18->io_state = 0x42;
      var_19(var_18,new_key,var_12);
      var_19(var_18,local_4a4,var_11);
      var_19(var_18,local_4a0,var_13);
    }
    var_3 = var_17.output_len;
    if (var_17.output_len < 0x400) {
      data = var_17.output;
LAB_0003c8f2:
      var_19(var_18,data,var_3);
    }
    else {
      var_26 = var_18->zbuffer_list;
      data = var_17.output;
      var_25 = 0x400;
      while( true ) {
        var_19(var_18,data,var_25);
        var_3 = var_3 - var_25;
        if ((var_3 == 0) || (var_26 == (type_7)0x0)) break;
        var_25 = var_18->zbuffer_size;
        data = var_26->output;
        if (var_3 < var_25) goto LAB_0003c8f2;
        var_26 = var_26->next;
      }
      if (var_3 != 0) {
                    /* WARNING: Subroutine does not return */
        var_4(var_18,"error writing ancillary chunked compressed data");
      }
    }
  }
  else {
    if (0x7fffffffU - (int)comp_00 < var_17.input_len) {
                    /* WARNING: Subroutine does not return */
      var_4(var_18,"iTXt: uncompressed text too long");
    }
    var_17.output_len = var_17.input_len;
    if (var_18 == (type_1)0x0) {
      var_19((type_1)0x0,new_key,var_12);
      var_19((type_1)0x0,local_4a4,var_11);
      var_19((type_1)0x0,local_4a0,var_13);
    }
    else {
      var_18->io_state = 0x22;
      var_20(var_21,(type_3)(comp_00->output + (var_17.input_len - 0xc)));
      var_20(var_21 + 4,0x69545874);
      var_22(var_18,var_21,8);
      var_18->chunk_name = 0x69545874;
      var_23(var_18);
      var_24(var_18,var_21 + 4,4);
      var_18->io_state = 0x42;
      var_19(var_18,new_key,var_12);
      var_19(var_18,local_4a4,var_11);
      var_19(var_18,local_4a0,var_13);
    }
    var_19(var_18,(type_8)var_10,var_17.output_len);
  }
  var_27(var_18);
  if (var_28 != *(int *)(var_1 + 0x14)) {
                    /* WARNING: Subroutine does not return */
    var_29();
  }
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator 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: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (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: (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: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (pointer_expression argument: (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (string_literal (string_content)) (identifier) (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (labeled_statement label: (statement_identifier) (expression_statement (assignment_expression left: (identifier) right: (true)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (number_literal)))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (labeled_statement label: (statement_identifier) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (string_literal (string_content)) (identifier) (identifier)))))))) alternative: (else_clause (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (goto_statement label: (statement_identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (false))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (number_literal)))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (string_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (string_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (string_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier)))))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (number_literal) right: (identifier)))) right: (parenthesized_expression (binary_expression left: (identifier) right: (binary_expression left: (number_literal) right: (parenthesized_expression (binary_expression left: (identifier) right: (identifier)))))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (identifier)))))) (if_statement condition: (parenthesized_expression (identifier)) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list))) right: (binary_expression left: (identifier) right: (number_literal)))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (identifier) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (identifier) (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal))))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (number_literal) right: (identifier)) right: (identifier))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (string_literal (string_content)) (identifier) (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (identifier) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal) (identifier) (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (binary_expression left: (identifier) right: (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (return_statement))))

/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Removing unreachable block (ram,0x0003c8a0) */
/* WARNING: Removing unreachable block (ram,0x0003c8b8) */
/* WARNING: Removing unreachable block (ram,0x0003c8d6) */
/* WARNING: Removing unreachable block (ram,0x0003c9e0) */
/* WARNING: Removing unreachable block (ram,0x0003c9ea) */
/* WARNING: Removing unreachable block (ram,0x0003c8de) */
/* WARNING: Removing unreachable block (ram,0x0003c8f0) */
/* WARNING: Removing unreachable block (ram,0x0003c8eb) */

void MASKED(int param_1,int param_2,undefined4 param_3,char *param_4,char *param_5,
                 char *param_6)

{
  bool bVar1;
  int iVar2;
  size_t sVar3;
  uint uVar4;
  int iVar5;
  undefined4 extraout_ECX;
  int iVar6;
  int in_GS_OFFSET;
  uint local_4a8;
  char *local_4a4;
  char *local_4a0;
  uint local_498;
  undefined1 local_47c [1026];
  undefined1 local_7a [4];
  undefined1 local_76 [4];
  undefined1 local_72;
  undefined1 auStack_71 [81];
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x3c509;
  local_4a4 = param_4;
  local_4a0 = param_5;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  iVar2 = FUN_00035490(param_1,param_3,&local_72);
  if (iVar2 == 0) {
                    /* WARNING: Subroutine does not return */
    png_error(param_1,"iTXt: invalid keyword",param_6,param_6);
  }
  if (param_2 == 0) {
LAB_0003c58f:
    bVar1 = true;
    auStack_71[iVar2] = 1;
  }
  else {
    if (param_2 < 1) {
      if (param_2 != -1) {
LAB_0003c9ae:
                    /* WARNING: Subroutine does not return */
        png_error(param_1,"iTXt: invalid compression",extraout_ECX,extraout_ECX);
      }
    }
    else if (param_2 != 1) {
      if (param_2 != 2) goto LAB_0003c9ae;
      goto LAB_0003c58f;
    }
    bVar1 = false;
    auStack_71[iVar2] = 0;
  }
  auStack_71[iVar2 + 1] = 0;
  iVar2 = iVar2 + 3;
  if (param_4 == (char *)0x0) {
    local_4a4 = "";
    local_4a8 = 1;
  }
  else {
    sVar3 = strlen(param_4);
    local_4a8 = sVar3 + 1;
  }
  if (param_5 == (char *)0x0) {
    local_4a0 = "";
    local_498 = 1;
  }
  else {
    sVar3 = strlen(param_5);
    local_498 = sVar3 + 1;
  }
  if (param_6 == (char *)0x0) {
    uVar4 = 0;
    param_6 = "";
  }
  else {
    uVar4 = strlen(param_6);
  }
  iVar6 = 0x7fffffff;
  if ((local_4a8 <= 0x7fffffffU - iVar2) && (local_498 <= 0x7fffffff - (local_4a8 + iVar2))) {
    iVar6 = local_4a8 + iVar2 + local_498;
  }
  if (bVar1) {
    iVar5 = FUN_0003a060();
    if ((iVar5 != 0) || (iVar5 = FUN_0003a340(), iVar5 != 0)) {
                    /* WARNING: Subroutine does not return */
      png_error(param_1,*(undefined4 *)(param_1 + 0xf8));
    }
    if (param_1 == 0) {
      png_write_chunk_data(0,&local_72,iVar2);
      png_write_chunk_data(0,local_4a4,local_4a8);
      png_write_chunk_data(0,local_4a0,local_498);
    }
    else {
      *(undefined4 *)(param_1 + 0x32c) = 0x22;
      png_save_uint_32(local_7a,iVar6);
      png_save_uint_32(local_76,0x69545874);
      FUN_000360c0(param_1,local_7a,8);
      *(undefined4 *)(param_1 + 0x178) = 0x69545874;
      FUN_00014f90(param_1);
      FUN_00014fc0(param_1,local_76,4);
      *(undefined4 *)(param_1 + 0x32c) = 0x42;
      png_write_chunk_data(param_1,&local_72,iVar2);
      png_write_chunk_data(param_1,local_4a4,local_4a8);
      png_write_chunk_data(param_1,local_4a0,local_498);
    }
    png_write_chunk_data(param_1,local_47c,0);
  }
  else {
    if (0x7fffffffU - iVar6 < uVar4) {
                    /* WARNING: Subroutine does not return */
      png_error(param_1,"iTXt: uncompressed text too long",uVar4,uVar4);
    }
    if (param_1 == 0) {
      png_write_chunk_data(0,&local_72,iVar2);
      png_write_chunk_data(0,local_4a4,local_4a8);
      png_write_chunk_data(0,local_4a0,local_498);
    }
    else {
      *(undefined4 *)(param_1 + 0x32c) = 0x22;
      png_save_uint_32(local_7a,uVar4 + iVar6);
      png_save_uint_32(local_76,0x69545874);
      FUN_000360c0(param_1,local_7a,8);
      *(undefined4 *)(param_1 + 0x178) = 0x69545874;
      FUN_00014f90(param_1);
      FUN_00014fc0(param_1,local_76,4);
      *(undefined4 *)(param_1 + 0x32c) = 0x42;
      png_write_chunk_data(param_1,&local_72,iVar2);
      png_write_chunk_data(param_1,local_4a4,local_4a8);
      png_write_chunk_data(param_1,local_4a0,local_498);
    }
    png_write_chunk_data(param_1,param_6,uVar4);
  }
  png_write_chunk_end(param_1);
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_0003f340();
  }
  return;
}

