// File: /workspace/github_cpp_makefile_star2_O1/trapexit[P]bbf/src/options.cpp
// Function: Options::process_arg(int, char const* const*, int)
AppError
Options::process_arg(const int          argc,
                     const char * const argv[],
                     const int          opt)
{
  switch(opt)
    {
    case 'f':
      force = true;
      break;
    case 'q':
      quiet++;
      break;
    case 'r':
      errno = 0;
      retries = ::strtol(optarg,NULL,BASE10);
      if(((errno == ERANGE) && (retries == LONG_MAX)) || (retries < 1))
        return AppError::argument_invalid("retries invalid");
      break;
    case 's':
      errno = 0;
      start_block = ::strtoull(optarg,NULL,BASE10);
      if((start_block == ULLONG_MAX) && (errno == ERANGE))
        return AppError::argument_invalid("start block value is invalid");
      break;
    case 'e':
      errno = 0;
      end_block = ::strtoull(optarg,NULL,BASE10);
      if((end_block == ULLONG_MAX) && (errno == ERANGE))
        return AppError::argument_invalid("end block value is invalid");
      break;
    case 'S':
      errno = 0;
      stepping = ::strtoull(optarg,NULL,BASE10);
      if((stepping == ULLONG_MAX) && (errno == ERANGE))
        return AppError::argument_invalid("invalid stepping");
      if((stepping > 65536) || (stepping < 1))
        return AppError::argument_invalid("stepping must be >= 1 && <= 65536");
      break;
    case 'M':
      errno = 0;
      max_errors = ::strtoull(optarg,NULL,BASE10);
      if((max_errors == ULLONG_MAX) && (errno == ERANGE))
        return AppError::argument_invalid("max errors value is invalid");
      break;
    case 'o':
      output_file = optarg;
      break;
    case 'i':
      input_file = optarg;
      break;
    case 'c':
      captcha = optarg;
      break;
    case 't':
      if(!strcmp(optarg,"os"))
        rwtype = OS;
      else if(!strcmp(optarg,"ata"))
        rwtype = ATA;
      else
        return AppError::argument_invalid("valid rwtype values are 'os' or 'ata'");
      break;
    case 'h':
      usage(std::cout);
      return AppError::success();
    case '?':
      return AppError::argument_invalid(std::string(argv[optind-1]) + " is unknown");
    }

  return AppError::success();
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x62, %r8d
jle 0xf382
addl $-0x63, %r8d
cmpl $0x11, %r8d
ja 0xf7c6
leaq 0x7794(%rip), %rax      # 0x16af0
movslq (%rax,%r8,4), %rcx
addq %rax, %rcx
jmpq *%rcx
movq 0x14c34(%rip), %rax     # 0x23fa0
movq (%rax), %r15
movq 0xa0(%r14), %r12
addq $0x98, %r14
jmp 0xf591
cmpl $0x3f, %r8d
je 0xf647
cmpl $0x4d, %r8d
je 0xf6a3
cmpl $0x53, %r8d
jne 0xf7c6
callq 0x4060
movq %rax, %r15
movl $0x0, (%rax)
movq 0x14beb(%rip), %rax     # 0x23fa0
movq (%rax), %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x4580
movq %rax, 0x48(%r14)
cmpq $-0x1, %rax
jne 0xf70b
cmpl $0x22, (%r15)
jne 0xf70b
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x77f0(%rip), %rsi      # 0x16bdc
leaq 0x77f9(%rip), %rdx      # 0x16bec
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
jmp 0xf748
callq 0x4060
movq %rax, %r15
movl $0x0, (%rax)
movq 0x14b80(%rip), %rax     # 0x23fa0
movq (%rax), %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x4580
movq %rax, 0x40(%r14)
cmpq $-0x1, %rax
jne 0xf7c6
cmpl $0x22, (%r15)
jne 0xf7c6
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x776a(%rip), %rsi      # 0x16bc1
leaq 0x777d(%rip), %rdx      # 0x16bdb
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
jmp 0xf748
movq 0x14b23(%rip), %rax     # 0x23fa0
movq (%rax), %r15
movq 0x80(%r14), %r12
addq $0x78, %r14
jmp 0xf591
movq 0x14b21(%rip), %rdi     # 0x23fb8
leaq 0x7939(%rip), %rsi      # 0x16dd7
movl $0xc22, %edx            # imm = 0xC22
callq 0x4500
jmp 0xf7c6
callq 0x4060
movq %rax, %r15
movl $0x0, (%rax)
movq 0x14ade(%rip), %rax     # 0x23fa0
movq (%rax), %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x4580
movq %rax, 0x38(%r14)
cmpq $-0x1, %rax
jne 0xf7c6
cmpl $0x22, (%r15)
jne 0xf7c6
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x76ab(%rip), %rsi      # 0x16ba4
leaq 0x76c0(%rip), %rdx      # 0x16bc0
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
jmp 0xf748
movq 0x14a81(%rip), %rax     # 0x23fa0
movq (%rax), %r15
leaq 0x6d61(%rip), %rsi      # 0x1628a
movq %r15, %rdi
callq 0x4590
testl %eax, %eax
je 0xf758
leaq 0x9afc(%rip), %rsi      # 0x1903c
movq %r15, %rdi
callq 0x4590
testl %eax, %eax
je 0xf7be
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x76cb(%rip), %rsi      # 0x16c2b
leaq 0x76e9(%rip), %rdx      # 0x16c50
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
jmp 0xf748
movq 0x14a1a(%rip), %rax     # 0x23fa0
movq (%rax), %r15
movq 0x60(%r14), %r12
addq $0x58, %r14
movq %r15, %rdi
callq 0x4200
movq %r14, %rdi
xorl %esi, %esi
movq %r12, %rdx
movq %r15, %rcx
movq %rax, %r8
callq 0x4640
jmp 0xf7c6
movb $0x1, 0xb8(%r14)
jmp 0xf7c6
callq 0x4060
movq %rax, %r15
movl $0x0, (%rax)
movq 0x149cd(%rip), %rax     # 0x23fa0
movq (%rax), %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x45a0
movq %rax, 0x30(%r14)
cmpl $0x22, (%r15)
sete %cl
movabsq $0x7fffffffffffffff, %rdx # imm = 0x7FFFFFFFFFFFFFFF
cmpq %rdx, %rax
sete %dl
andb %cl, %dl
testq %rax, %rax
setle %al
orb %dl, %al
cmpb $0x1, %al
jne 0xf7c6
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x7575(%rip), %rsi      # 0x16b94
leaq 0x757d(%rip), %rdx      # 0x16ba3
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
jmp 0xf748
incl 0x28(%r14)
jmp 0xf7c6
movq 0x14972(%rip), %rax     # 0x23fc0
movslq (%rax), %rax
movq -0x8(%rcx,%rax,8), %rsi
leaq 0x28(%rsp), %rdi
leaq 0x27(%rsp), %rdx
callq 0xfe6c
leaq 0x75e5(%rip), %rsi      # 0x16c51
leaq 0x28(%rsp), %rdi
callq 0x4760
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0xf762
movq %rdx, (%rsp)
movq (%rcx), %rdx
movq %rdx, 0x10(%rsp)
jmp 0xf769
callq 0x4060
movq %rax, %r15
movl $0x0, (%rax)
movq 0x148e8(%rip), %rax     # 0x23fa0
movq (%rax), %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x4580
movq %rax, 0x50(%r14)
cmpq $-0x1, %rax
jne 0xf7c6
cmpl $0x22, (%r15)
jne 0xf7c6
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x7520(%rip), %rsi      # 0x16c0f
leaq 0x7534(%rip), %rdx      # 0x16c2a
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
jmp 0xf748
movq $-0x10001, %rcx         # imm = 0xFFFEFFFF
addq %rcx, %rax
cmpq %rcx, %rax
ja 0xf7c6
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x74bf(%rip), %rsi      # 0x16bed
leaq 0x74d9(%rip), %rdx      # 0x16c0e
movq %rsp, %rdi
callq 0x75e0
movq %rsp, %rsi
movq %rbx, %rdi
callq 0xde92
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0xf7ce
movq 0x10(%rsp), %rsi
jmp 0xf7b4
movl $0x1, 0x4(%r14)
jmp 0xf7c6
movups (%rcx), %xmm0
movups %xmm0, (%r14)
movq 0x8(%rax), %rdx
movq %rsp, %rsi
movq %rdx, 0x8(%rsi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq %rbx, %rdi
callq 0xde92
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0xf7a1
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x44b0
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf7ce
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x44b0
jmp 0xf7ce
movl $0x0, 0x4(%r14)
movq %rbx, %rdi
callq 0xdd7c
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0xf7f5
jmp 0xf7f5
jmp 0xf845
jmp 0xf845
jmp 0xf7f5
jmp 0xf7f5
jmp 0xf845
jmp 0xf845
jmp 0xf7f5
jmp 0xf845
jmp 0xf7f5
jmp 0xf845
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0xf848
movq 0x10(%rsp), %rsi
jmp 0xf83b
jmp 0xf845
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0xf828
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x44b0
jmp 0xf828
movq %rax, %rbx
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xf848
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x44b0
jmp 0xf848
movq %rax, %rbx
movq %rbx, %rdi
callq 0x46f0