// File: /workspace/github_c_makefile_star2_O0/OpenKMIP[P]libkmip/src/kmip.c
// Function: kmip_decode_application_specific_information
int
kmip_decode_application_specific_information(KMIP *ctx, ApplicationSpecificInformation *value)
{
    CHECK_BUFFER_FULL(ctx, 8);

    kmip_init_application_specific_information(value);

    int result = 0;
    int32 tag_type = 0;
    uint32 length = 0;

    kmip_decode_int32_be(ctx, &tag_type);
    CHECK_TAG_TYPE(ctx, tag_type, KMIP_TAG_APPLICATION_SPECIFIC_INFORMATION, KMIP_TYPE_STRUCTURE);

    kmip_decode_length(ctx, &length);
    CHECK_BUFFER_FULL(ctx, length);

    if(kmip_is_tag_next(ctx, KMIP_TAG_APPLICATION_NAMESPACE))
    {
        value->application_namespace = ctx->calloc_func(ctx->state, 1, sizeof(TextString));
        CHECK_NEW_MEMORY(ctx, value->application_namespace, sizeof(TextString), "Application Namespace text string");

        result = kmip_decode_text_string(ctx, KMIP_TAG_APPLICATION_NAMESPACE, value->application_namespace);
        CHECK_RESULT(ctx, result);
    }
    else
    {
        kmip_set_error_message(ctx, "The ApplicationSpecificInformation encoding is missing the application name field.");
        kmip_push_error_frame(ctx, __func__, __LINE__);
        return(KMIP_INVALID_ENCODING);
    }

    if(kmip_is_tag_next(ctx, KMIP_TAG_APPLICATION_DATA))
    {
        value->application_data = ctx->calloc_func(ctx->state, 1, sizeof(TextString));
        CHECK_NEW_MEMORY(ctx, value->application_data, sizeof(TextString), "Application Data text string");

        result = kmip_decode_text_string(ctx, KMIP_TAG_APPLICATION_DATA, value->application_data);
        CHECK_RESULT(ctx, result);
    }
    else
    {
        if(ctx->version < KMIP_1_3)
        {
            kmip_set_error_message(ctx, "The ApplicationSpecificInformation encoding is missing the application data field.");
            kmip_push_error_frame(ctx, __func__, __LINE__);
            return(KMIP_INVALID_ENCODING);
        }
    }

    return(KMIP_OK);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
movq -0x10(%rbp), %rdx
movq (%rdx), %rdx
subq %rdx, %rcx
subq %rcx, %rax
cmpq $0x8, %rax
jae 0x19114
movq -0x10(%rbp), %rdi
leaq 0xc65f(%rip), %rsi      # 0x2575d
movl $0x2537, %edx           # imm = 0x2537
callq 0x6f20
movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE
jmp 0x193f6
jmp 0x19116
movq -0x18(%rbp), %rdi
callq 0x6060
movl $0x0, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movq -0x10(%rbp), %rdi
leaq -0x20(%rbp), %rsi
callq 0x6b10
movl -0x20(%rbp), %eax
sarl $0x8, %eax
cmpl $0x420004, %eax         # imm = 0x420004
je 0x1916f
movq -0x10(%rbp), %rdi
leaq 0xc604(%rip), %rsi      # 0x2575d
movl $0x2540, %edx           # imm = 0x2540
callq 0x6f20
movl $0xfffffffc, -0x4(%rbp) # imm = 0xFFFFFFFC
jmp 0x193f6
movl -0x20(%rbp), %eax
andl $0xff, %eax
cmpl $0x1, %eax
je 0x1919d
movq -0x10(%rbp), %rdi
leaq 0xc5d6(%rip), %rsi      # 0x2575d
movl $0x2540, %edx           # imm = 0x2540
callq 0x6f20
movl $0xfffffffb, -0x4(%rbp) # imm = 0xFFFFFFFB
jmp 0x193f6
jmp 0x1919f
jmp 0x191a1
movq -0x10(%rbp), %rdi
leaq -0x24(%rbp), %rsi
callq 0x6520
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
movq -0x10(%rbp), %rdx
movq (%rdx), %rdx
subq %rdx, %rcx
subq %rcx, %rax
movl -0x24(%rbp), %ecx
cmpq %rcx, %rax
jae 0x191f4
movq -0x10(%rbp), %rdi
leaq 0xc57f(%rip), %rsi      # 0x2575d
movl $0x2543, %edx           # imm = 0x2543
callq 0x6f20
movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE
jmp 0x193f6
jmp 0x191f6
movq -0x10(%rbp), %rdi
movl $0x420003, %esi         # imm = 0x420003
callq 0x6300
cmpl $0x0, %eax
je 0x192bd
movq -0x10(%rbp), %rax
movq 0x868(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x890(%rcx), %rdi
movl $0x1, %esi
movl $0x10, %edx
callq *%rax
movq %rax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x18(%rbp), %rax
cmpq $0x0, (%rax)
jne 0x19279
movq -0x10(%rbp), %rdi
movl $0x10, %esi
leaq 0xc537(%rip), %rdx      # 0x2578a
callq 0x6cd0
movq -0x10(%rbp), %rdi
leaq 0xc4fa(%rip), %rsi      # 0x2575d
movl $0x2548, %edx           # imm = 0x2548
callq 0x6f20
movl $0xfffffff4, -0x4(%rbp) # imm = 0xFFFFFFF4
jmp 0x193f6
jmp 0x1927b
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq (%rax), %rdx
movl $0x420003, %esi         # imm = 0x420003
callq 0x65b0
movl %eax, -0x1c(%rbp)
cmpl $0x0, -0x1c(%rbp)
je 0x192b9
movq -0x10(%rbp), %rdi
leaq 0xc4b9(%rip), %rsi      # 0x2575d
movl $0x254b, %edx           # imm = 0x254B
callq 0x6f20
movl -0x1c(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x193f6
jmp 0x192bb
jmp 0x192ee
movq -0x10(%rbp), %rdi
leaq 0xc4e4(%rip), %rsi      # 0x257ac
callq 0x68b0
movq -0x10(%rbp), %rdi
leaq 0xc485(%rip), %rsi      # 0x2575d
movl $0x2550, %edx           # imm = 0x2550
callq 0x6f20
movl $0xffffffed, -0x4(%rbp) # imm = 0xFFFFFFED
jmp 0x193f6
movq -0x10(%rbp), %rdi
movl $0x420002, %esi         # imm = 0x420002
callq 0x6300
cmpl $0x0, %eax
je 0x193b5
movq -0x10(%rbp), %rax
movq 0x868(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x890(%rcx), %rdi
movl $0x1, %esi
movl $0x10, %edx
callq *%rax
movq %rax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x19373
movq -0x10(%rbp), %rdi
movl $0x10, %esi
leaq 0xc4b2(%rip), %rdx      # 0x257ff
callq 0x6cd0
movq -0x10(%rbp), %rdi
leaq 0xc400(%rip), %rsi      # 0x2575d
movl $0x2557, %edx           # imm = 0x2557
callq 0x6f20
movl $0xfffffff4, -0x4(%rbp) # imm = 0xFFFFFFF4
jmp 0x193f6
jmp 0x19375
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rdx
movl $0x420002, %esi         # imm = 0x420002
callq 0x65b0
movl %eax, -0x1c(%rbp)
cmpl $0x0, -0x1c(%rbp)
je 0x193b1
movq -0x10(%rbp), %rdi
leaq 0xc3be(%rip), %rsi      # 0x2575d
movl $0x255a, %edx           # imm = 0x255A
callq 0x6f20
movl -0x1c(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x193f6
jmp 0x193b3
jmp 0x193ef
movq -0x10(%rbp), %rax
cmpl $0x3, 0x18(%rax)
jae 0x193ed
movq -0x10(%rbp), %rdi
leaq 0xc452(%rip), %rsi      # 0x2581c
callq 0x68b0
movq -0x10(%rbp), %rdi
leaq 0xc383(%rip), %rsi      # 0x2575d
movl $0x2561, %edx           # imm = 0x2561
callq 0x6f20
movl $0xffffffed, -0x4(%rbp) # imm = 0xFFFFFFED
jmp 0x193f6
jmp 0x193ef
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nop