// File: /workspace/github_c_makefile_star2_O1/zenlinux[P]cwm/cwm.c
// Function: main
int
main(int argc, char **argv)
{
	const char	*conf_file = NULL;
	char		*display_name = NULL;
	int		 ch;

	if (!setlocale(LC_CTYPE, "") || !XSupportsLocale())
		warnx("no locale support");
	mbtowc(NULL, NULL, MB_CUR_MAX);

	cwm_argv = argv;
	while ((ch = getopt(argc, argv, "c:d:")) != -1) {
		switch (ch) {
		case 'c':
			conf_file = optarg;
			break;
		case 'd':
			display_name = optarg;
			break;
		default:
			usage();
		}
	}
	argc -= optind;
	argv += optind;

	if (signal(SIGCHLD, sigchld_cb) == SIG_ERR)
		err(1, "signal");

	dpy_init(display_name);

	bzero(&Conf, sizeof(Conf));
	conf_setup(&Conf, conf_file);
	xu_getatoms();
	x_setup();

	xev_loop();

	x_teardown();

	return (0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp            # imm = 0x118
movq %rsi, %r14
movl %edi, %ebp
leaq 0x8696(%rip), %rsi      # 0xe18f
xorl %edi, %edi
callq 0x57f0
testq %rax, %rax
je 0x5b0e
callq 0x52d0
testl %eax, %eax
jne 0x5b1c
leaq 0x84ef(%rip), %rdi      # 0xe004
xorl %eax, %eax
callq 0x5140
callq 0x5380
xorl %ebx, %ebx
xorl %edi, %edi
xorl %esi, %esi
movq %rax, %rdx
callq 0x5080
movq %r14, 0xec32(%rip)      # 0x14768
leaq 0x84d9(%rip), %r12      # 0xe016
movq 0xe494(%rip), %r13      # 0x13fd8
xorl %r15d, %r15d
movl %ebp, %edi
movq %r14, %rsi
movq %r12, %rdx
callq 0x51c0
cmpl $0x64, %eax
jne 0x5b5f
movq (%r13), %r15
jmp 0x5b47
cmpl $-0x1, %eax
je 0x5b73
cmpl $0x63, %eax
jne 0x5f09
movq (%r13), %rbx
jmp 0x5b47
leaq 0x3f2(%rip), %rsi       # 0x5f6c
movl $0x11, %edi
callq 0x5510
cmpq $-0x1, %rax
je 0x5f0e
leaq 0x416(%rip), %rdi       # 0x5fab
callq 0x5780
movq %r15, %rdi
callq 0x52b0
movq %rax, 0x10caf(%rip)     # 0x16858
testq %rax, %rax
je 0x5f21
leaq 0x3f5(%rip), %rdi       # 0x5fae
callq 0x5780
movq 0x10c93(%rip), %rdi     # 0x16858
movq 0xe8(%rdi), %rax
movslq 0xe0(%rdi), %rcx
shlq $0x7, %rcx
movq 0x10(%rax,%rcx), %rsi
movl $0x100000, %edx         # imm = 0x100000
callq 0x5570
movq 0x10c6b(%rip), %rdi     # 0x16858
xorl %esi, %esi
callq 0x55c0
leaq 0x3b0(%rip), %rdi       # 0x5fab
callq 0x5780
movq 0x10c51(%rip), %rdi     # 0x16858
leaq 0x10c7e(%rip), %rsi     # 0x1688c
leaq 0x20(%rsp), %rdx
callq 0x5240
movl %eax, 0x10c6a(%rip)     # 0x16888
leaq 0xeb4b(%rip), %r14      # 0x14770
movl $0x20e8, %edx           # imm = 0x20E8
movq %r14, %rdi
xorl %esi, %esi
callq 0x5090
movq %r14, %rdi
movq %rbx, %rsi
callq 0x9ac3
callq 0x8e5d
movq 0x10c0d(%rip), %rdi     # 0x16858
xorl %esi, %esi
callq 0x5050
movq %rax, 0x10c07(%rip)     # 0x16860
movq 0x10bf8(%rip), %rdi     # 0x16858
movl $0x34, %esi
callq 0x5050
movq %rax, 0x10bf7(%rip)     # 0x16868
movq 0x10be0(%rip), %rdi     # 0x16858
movl $0x44, %esi
callq 0x5050
movq %rax, 0x10be7(%rip)     # 0x16870
movq 0x10bc8(%rip), %rdi     # 0x16858
movl $0x5c, %esi
callq 0x5050
movq %rax, 0x10bd7(%rip)     # 0x16878
movq 0x10bb0(%rip), %rdi     # 0x16858
movl $0xe, %esi
callq 0x5050
movq %rax, 0x10bc7(%rip)     # 0x16880
movq 0x10b98(%rip), %rax     # 0x16858
cmpl $0x0, 0xe4(%rax)
jle 0x5e9a
xorl %r12d, %r12d
leaq 0xea99(%rip), %rbx      # 0x14770
leaq 0x4(%rsp), %rbp
leaq 0x20(%rsp), %r14
movl $0x1, %edi
movl $0x2f0, %esi            # imm = 0x2F0
callq 0x61a8
movq %rax, %r15
movl %r12d, 0x10(%rax)
movq 0x10b5a(%rip), %rax     # 0x16858
movq 0xe8(%rax), %rax
movq %r12, %rcx
shlq $0x7, %rcx
movq 0x10(%rax,%rcx), %rax
movq %rax, 0x18(%r15)
movq %r15, %rdi
callq 0x8ec6
movq %r15, %rdi
callq 0x8f20
movq %rbx, %rdi
movq %r15, %rsi
callq 0x9480
movq %r15, %rdi
callq 0x60b3
movq %rbx, %rdi
movq %r15, %rsi
callq 0x94c3
movq %r15, %rdi
callq 0xa378
movq %rbx, %rdi
movq %r15, %rsi
callq 0x948c
leaq 0xd8(%r15), %rax
movq $0x0, 0xd8(%r15)
movq %rax, 0xe0(%r15)
movq %r15, %rdi
callq 0x7444
movq 0x10af2(%rip), %rax     # 0x16870
movq %rax, 0x110(%rsp)
movq $0xd8003c, 0xf0(%rsp) # imm = 0xD8003C
movq 0x10abf(%rip), %rdi     # 0x16858
movq 0x18(%r15), %rsi
movl $0x4800, %edx           # imm = 0x4800
leaq 0xa8(%rsp), %rcx
callq 0x58b0
movq 0x10aa2(%rip), %rdi     # 0x16858
movq 0x18(%r15), %rsi
leaq 0x18(%rsp), %rdx
leaq 0x10(%rsp), %rcx
leaq 0x8(%rsp), %r8
movq %rbp, %r9
callq 0x5860
cmpl $0x0, 0x4(%rsp)
je 0x5e26
xorl %r13d, %r13d
movq 0x10a76(%rip), %rdi     # 0x16858
movq 0x8(%rsp), %rax
movq (%rax,%r13,8), %rsi
movq %r14, %rdx
callq 0x5720
cmpl $0x0, 0x98(%rsp)
jne 0x5e1a
cmpl $0x2, 0x7c(%rsp)
jne 0x5e1a
movq 0x8(%rsp), %rax
movq (%rax,%r13,8), %rdi
movq %r15, %rsi
movl $0x1, %edx
callq 0x6209
incq %r13
movl 0x4(%rsp), %eax
cmpq %rax, %r13
jb 0x5ddb
movq 0x8(%rsp), %rdi
callq 0x5060
movq %r15, %rdi
callq 0x5fe5
cmpl $0x0, 0x10a49(%rip)     # 0x16888
je 0x5e56
movq 0x10a10(%rip), %rdi     # 0x16858
movq 0x18(%r15), %rsi
movl $0x1, %edx
callq 0x52f0
movq 0x109fb(%rip), %rdi     # 0x16858
xorl %esi, %esi
callq 0x55c0
movq $0x0, (%r15)
movq 0xe616(%rip), %rax      # 0x14488
movq %rax, 0x8(%r15)
movq %r15, (%rax)
movq %r15, 0xe608(%rip)      # 0x14488
incq %r12
movq 0x109ce(%rip), %rax     # 0x16858
movslq 0xe4(%rax), %rax
cmpq %rax, %r12
jl 0x5ce1
movq 0xe8cf(%rip), %rbx      # 0x14770
testq %rbx, %rbx
je 0x5ec0
leaq 0xe8c3(%rip), %r14      # 0x14770
movq %r14, %rdi
movq %rbx, %rsi
callq 0x9c45
movq (%rbx), %rbx
testq %rbx, %rbx
jne 0x5ead
callq 0xa2c0
movq 0xe5b4(%rip), %rbx      # 0x14480
testq %rbx, %rbx
je 0x5ee9
movq 0x10980(%rip), %rdi     # 0x16858
movq 0x98(%rbx), %rsi
callq 0x5420
movq (%rbx), %rbx
jmp 0x5ecc
movq 0x10968(%rip), %rdi     # 0x16858
callq 0x5360
xorl %eax, %eax
addq $0x118, %rsp            # imm = 0x118
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x58e0
leaq 0x8106(%rip), %rsi      # 0xe01b
movl $0x1, %edi
xorl %eax, %eax
callq 0x54c0
movq %r15, %rdi
callq 0x5440
leaq 0x8114(%rip), %rsi      # 0xe044
movl $0x1, %edi
movq %rax, %rdx
xorl %eax, %eax
callq 0x5700