
/* WARNING: Unknown calling convention */

int png_get_unknown_chunks
              (png_const_structrp png_ptr,png_inforp info_ptr,png_unknown_chunkpp unknowns)

{
  if ((info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&
     (png_ptr != (png_const_structrp)0x0)) {
    *unknowns = info_ptr->unknown_chunks;
    return info_ptr->unknown_chunks_num;
  }
  return 0;
}



undefined4 png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)

{
  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {
    *param_3 = *(undefined8 *)(param_2 + 0x130);
    return *(undefined4 *)(param_2 + 0x138);
  }
  return 0;
}


TEST RSI,RSI
SETNZ CL
TEST RDX,RDX
SETNZ AL
TEST CL,AL
JZ 0x0010c7bf
TEST RDI,RDI
JNZ 0x0010c7c5
MOV EAX,0x0
RET
MOV RAX,qword ptr [RSI + 0x130]
MOV qword ptr [RDX],RAX
MOV EAX,dword ptr [RSI + 0x138]
RET
(translation_unit "undefined4 png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)\n\n{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}\n\n" (function_definition "undefined4 png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)\n\n{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}" type_identifier (function_declarator "png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)" identifier (parameter_list "(long param_1,long param_2,undefined8 *param_3)" ( (parameter_declaration "long param_1" (sized_type_specifier "long" long) identifier) , (parameter_declaration "long param_2" (sized_type_specifier "long" long) identifier) , (parameter_declaration "undefined8 *param_3" type_identifier (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}" { (if_statement "if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }" if (parenthesized_expression "((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0))" ( (binary_expression "(param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)" (parenthesized_expression "(param_2 != 0 && param_3 != (undefined8 *)0x0)" ( (binary_expression "param_2 != 0 && param_3 != (undefined8 *)0x0" (binary_expression "param_2 != 0" identifier != number_literal) && (binary_expression "param_3 != (undefined8 *)0x0" identifier != (cast_expression "(undefined8 *)0x0" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal))) )) && (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }" { (expression_statement "*param_3 = *(undefined8 *)(param_2 + 0x130);" (assignment_expression "*param_3 = *(undefined8 *)(param_2 + 0x130)" (pointer_expression "*param_3" * identifier) = (pointer_expression "*(undefined8 *)(param_2 + 0x130)" * (cast_expression "(undefined8 *)(param_2 + 0x130)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x130)" ( (binary_expression "param_2 + 0x130" identifier + number_literal) ))))) ;) (return_statement "return *(undefined4 *)(param_2 + 0x138);" return (pointer_expression "*(undefined4 *)(param_2 + 0x138)" * (cast_expression "(undefined4 *)(param_2 + 0x138)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x138)" ( (binary_expression "param_2 + 0x138" identifier + number_literal) )))) ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "/* WARNING: Unknown calling convention */\n\nint png_get_unknown_chunks\n              (png_const_structrp png_ptr,png_inforp info_ptr,png_unknown_chunkpp unknowns)\n\n{\n  if ((info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&\n     (png_ptr != (png_const_structrp)0x0)) {\n    *unknowns = info_ptr->unknown_chunks;\n    return info_ptr->unknown_chunks_num;\n  }\n  return 0;\n}\n\n" comment (function_definition "int png_get_unknown_chunks\n              (png_const_structrp png_ptr,png_inforp info_ptr,png_unknown_chunkpp unknowns)\n\n{\n  if ((info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&\n     (png_ptr != (png_const_structrp)0x0)) {\n    *unknowns = info_ptr->unknown_chunks;\n    return info_ptr->unknown_chunks_num;\n  }\n  return 0;\n}" primitive_type (function_declarator "png_get_unknown_chunks\n              (png_const_structrp png_ptr,png_inforp info_ptr,png_unknown_chunkpp unknowns)" identifier (parameter_list "(png_const_structrp png_ptr,png_inforp info_ptr,png_unknown_chunkpp unknowns)" ( (parameter_declaration "png_const_structrp png_ptr" type_identifier identifier) , (parameter_declaration "png_inforp info_ptr" type_identifier identifier) , (parameter_declaration "png_unknown_chunkpp unknowns" type_identifier identifier) ))) (compound_statement "{\n  if ((info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&\n     (png_ptr != (png_const_structrp)0x0)) {\n    *unknowns = info_ptr->unknown_chunks;\n    return info_ptr->unknown_chunks_num;\n  }\n  return 0;\n}" { (if_statement "if ((info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&\n     (png_ptr != (png_const_structrp)0x0)) {\n    *unknowns = info_ptr->unknown_chunks;\n    return info_ptr->unknown_chunks_num;\n  }" if (parenthesized_expression "((info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&\n     (png_ptr != (png_const_structrp)0x0))" ( (binary_expression "(info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0) &&\n     (png_ptr != (png_const_structrp)0x0)" (parenthesized_expression "(info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0)" ( (binary_expression "info_ptr != (png_inforp)0x0 && unknowns != (png_unknown_chunkpp)0x0" (binary_expression "info_ptr != (png_inforp)0x0" identifier != (cast_expression "(png_inforp)0x0" ( (type_descriptor "png_inforp" type_identifier) ) number_literal)) && (binary_expression "unknowns != (png_unknown_chunkpp)0x0" identifier != (cast_expression "(png_unknown_chunkpp)0x0" ( (type_descriptor "png_unknown_chunkpp" type_identifier) ) number_literal))) )) && (parenthesized_expression "(png_ptr != (png_const_structrp)0x0)" ( (binary_expression "png_ptr != (png_const_structrp)0x0" identifier != (cast_expression "(png_const_structrp)0x0" ( (type_descriptor "png_const_structrp" type_identifier) ) number_literal)) ))) )) (compound_statement "{\n    *unknowns = info_ptr->unknown_chunks;\n    return info_ptr->unknown_chunks_num;\n  }" { (expression_statement "*unknowns = info_ptr->unknown_chunks;" (assignment_expression "*unknowns = info_ptr->unknown_chunks" (pointer_expression "*unknowns" * identifier) = (field_expression "info_ptr->unknown_chunks" identifier -> field_identifier)) ;) (return_statement "return info_ptr->unknown_chunks_num;" return (field_expression "info_ptr->unknown_chunks_num" identifier -> field_identifier) ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "undefined4 png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)\n\n{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}\n\n" (function_definition "undefined4 png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)\n\n{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}" type_identifier (function_declarator "png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)" identifier (parameter_list "(long param_1,long param_2,undefined8 *param_3)" ( (parameter_declaration "long param_1" (sized_type_specifier "long" long) identifier) , (parameter_declaration "long param_2" (sized_type_specifier "long" long) identifier) , (parameter_declaration "undefined8 *param_3" type_identifier (pointer_declarator "*param_3" * identifier)) ))) (compound_statement "{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}" { (if_statement "if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }" if (parenthesized_expression "((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0))" ( (binary_expression "(param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)" (parenthesized_expression "(param_2 != 0 && param_3 != (undefined8 *)0x0)" ( (binary_expression "param_2 != 0 && param_3 != (undefined8 *)0x0" (binary_expression "param_2 != 0" identifier != number_literal) && (binary_expression "param_3 != (undefined8 *)0x0" identifier != (cast_expression "(undefined8 *)0x0" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal))) )) && (parenthesized_expression "(param_1 != 0)" ( (binary_expression "param_1 != 0" identifier != number_literal) ))) )) (compound_statement "{\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }" { (expression_statement "*param_3 = *(undefined8 *)(param_2 + 0x130);" (assignment_expression "*param_3 = *(undefined8 *)(param_2 + 0x130)" (pointer_expression "*param_3" * identifier) = (pointer_expression "*(undefined8 *)(param_2 + 0x130)" * (cast_expression "(undefined8 *)(param_2 + 0x130)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x130)" ( (binary_expression "param_2 + 0x130" identifier + number_literal) ))))) ;) (return_statement "return *(undefined4 *)(param_2 + 0x138);" return (pointer_expression "*(undefined4 *)(param_2 + 0x138)" * (cast_expression "(undefined4 *)(param_2 + 0x138)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x138)" ( (binary_expression "param_2 + 0x138" identifier + number_literal) )))) ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration (sized_type_specifier long) IDENT) , (parameter_declaration (sized_type_specifier long) IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (binary_expression IDENT != LIT) && (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT))) )) && (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (return_statement return (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) })) (return_statement return LIT ;) })))
(function_definition "undefined4 png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)\n\n{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}" (type_identifier "undefined4") (function_declarator "png_get_unknown_chunks(long param_1,long param_2,undefined8 *param_3)" (identifier "png_get_unknown_chunks") (parameter_list "(long param_1,long param_2,undefined8 *param_3)" (( "(") (parameter_declaration "long param_1" (sized_type_specifier "long" (long "long")) (identifier "param_1")) (, ",") (parameter_declaration "long param_2" (sized_type_specifier "long" (long "long")) (identifier "param_2")) (, ",") (parameter_declaration "undefined8 *param_3" (type_identifier "undefined8") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) () ")"))) (compound_statement "{\n  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }\n  return 0;\n}" ({ "{") (if_statement "if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }" (if "if") (parenthesized_expression "((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0))" (( "(") (binary_expression "(param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)" (parenthesized_expression "(param_2 != 0 && param_3 != (undefined8 *)0x0)" (( "(") (binary_expression "param_2 != 0 && param_3 != (undefined8 *)0x0" (binary_expression "param_2 != 0" (identifier "param_2") (!= "!=") (number_literal "0")) (&& "&&") (binary_expression "param_3 != (undefined8 *)0x0" (identifier "param_3") (!= "!=") (cast_expression "(undefined8 *)0x0" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0")))) () ")")) (&& "&&") (parenthesized_expression "(param_1 != 0)" (( "(") (binary_expression "param_1 != 0" (identifier "param_1") (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n    *param_3 = *(undefined8 *)(param_2 + 0x130);\n    return *(undefined4 *)(param_2 + 0x138);\n  }" ({ "{") (expression_statement "*param_3 = *(undefined8 *)(param_2 + 0x130);" (assignment_expression "*param_3 = *(undefined8 *)(param_2 + 0x130)" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (= "=") (pointer_expression "*(undefined8 *)(param_2 + 0x130)" (* "*") (cast_expression "(undefined8 *)(param_2 + 0x130)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x130)" (( "(") (binary_expression "param_2 + 0x130" (identifier "param_2") (+ "+") (number_literal "0x130")) () ")"))))) (; ";")) (return_statement "return *(undefined4 *)(param_2 + 0x138);" (return "return") (pointer_expression "*(undefined4 *)(param_2 + 0x138)" (* "*") (cast_expression "(undefined4 *)(param_2 + 0x138)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x138)" (( "(") (binary_expression "param_2 + 0x138" (identifier "param_2") (+ "+") (number_literal "0x138")) () ")")))) (; ";")) (} "}"))) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}")))

/* WARNING: Unknown calling convention */

int function_1
              (type_1 var_3,type_2 var_1,type_3 var_2)

{
  if ((var_1 != (type_2)0x0 && var_2 != (type_3)0x0) &&
     (var_3 != (type_1)0x0)) {
    *var_2 = var_1->unknown_chunks;
    return var_1->unknown_chunks_num;
  }
  return 0;
}


(translation_unit (function_definition type: (type_identifier) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (sized_type_specifier) declarator: (identifier)) (parameter_declaration type: (sized_type_specifier) declarator: (identifier)) (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal))))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (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))))))) (return_statement (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)))))))) (return_statement (number_literal)))))

undefined4 MASKED(long param_1,long param_2,undefined8 *param_3)

{
  if ((param_2 != 0 && param_3 != (undefined8 *)0x0) && (param_1 != 0)) {
    *param_3 = *(undefined8 *)(param_2 + 0x130);
    return *(undefined4 *)(param_2 + 0x138);
  }
  return 0;
}

