// File: /workspace/github_c_makefile_star2_O0/kisom[P]rmtmp/rmtmp.c
// Function: main
int
main(int argc, char *argv[])
{
	char	*tmpdir = NULL;
	int	 opt;

	if (argc == 1) {
		fprintf(stderr, "no prefix given\n");
		return EXIT_FAILURE;
	}

	while ((opt = getopt(argc, (char *const *) argv, "d:hvV")) != -1) {
		switch (opt) {
		case 'd':
			tmpdir = optarg;
			break;
		case 'h':
			usage();
			/* NOT REACHED */
			break;
		case 'v':
			verbose = 1;
			break;
		case 'V':
			version();
			exit(EX_USAGE);
		default:
			/* NOT REACHED */
			fprintf(stderr, "invalid argument!\n");
			return EXIT_FAILURE;
		}
	}

	argc -= optind;
	argv += optind;

	if (argc > 1)
		fprintf(stderr, "warning: multiple prefixes selected, "
		    "but only the first will be used.\n");

	if (NULL == tmpdir) {
		if ((NULL == (tmpdir = getenv("TMPDIR"))) || (*tmpdir == '\0'))
			tmpdir = (char *)TMP_DIR;
	}

	if (remove_tmp(tmpdir, argv[0]) != 0) {
		fprintf(stderr, "failed to remove some files.\n");
		return EXIT_FAILURE;
	}
	return EXIT_SUCCESS;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x18(%rbp)
cmpl $0x1, -0x8(%rbp)
jne 0x4016d8
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rdi
leaq 0x979c3(%rip), %rsi     # 0x499088
movb $0x0, %al
callq 0x40b960
movl $0x1, -0x4(%rbp)
jmp 0x40183b
jmp 0x4016da
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
leaq 0x979b1(%rip), %rdx     # 0x499099
callq 0x4508c0
movl %eax, -0x1c(%rbp)
cmpl $-0x1, %eax
je 0x401779
movl -0x1c(%rbp), %eax
addl $-0x56, %eax
movl %eax, %ecx
movq %rcx, -0x28(%rbp)
subl $0x20, %eax
ja 0x401750
movq -0x28(%rbp), %rax
leaq 0x978ef(%rip), %rcx     # 0x499004
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq $0x4d0240, %rax         # imm = 0x4D0240
movq (%rax), %rax
movq %rax, -0x18(%rbp)
jmp 0x401774
callq 0x401850
jmp 0x401774
movl $0x1, 0xc9bb1(%rip)     # 0x4cb2f0
jmp 0x401774
callq 0x4018c0
movl $0x40, %edi
callq 0x40ae30
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rdi
leaq 0x9793e(%rip), %rsi     # 0x49909f
movb $0x0, %al
callq 0x40b960
movl $0x1, -0x4(%rbp)
jmp 0x40183b
jmp 0x4016da
movq $0x4ca080, %rax         # imm = 0x4CA080
movl (%rax), %ecx
movl -0x8(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x8(%rbp)
movq $0x4ca080, %rax         # imm = 0x4CA080
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
cmpl $0x1, -0x8(%rbp)
jle 0x4017c3
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rdi
leaq 0x978f6(%rip), %rsi     # 0x4990b2
movb $0x0, %al
callq 0x40b960
xorl %eax, %eax
cmpq -0x18(%rbp), %rax
jne 0x4017fe
leaq 0x97927(%rip), %rdi     # 0x4990f9
callq 0x40aae0
movq %rax, %rcx
movq %rcx, -0x18(%rbp)
xorl %eax, %eax
cmpq %rcx, %rax
je 0x4017f1
movq -0x18(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0x4017fc
leaq 0x97908(%rip), %rax     # 0x499100
movq %rax, -0x18(%rbp)
jmp 0x4017fe
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
callq 0x4018f0
cmpl $0x0, %eax
je 0x401834
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rdi
leaq 0x978e1(%rip), %rsi     # 0x499105
movb $0x0, %al
callq 0x40b960
movl $0x1, -0x4(%rbp)
jmp 0x40183b
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)