// File: /workspace/github_c_makefile_star2_O2/GangZhuo[P]dohclient/src/chnroute.c
// Function: chnroute_parse
int chnroute_parse(chnroute_ctx ctx, const char* filename)
{
	char* s, * p, *saveptr = NULL;
	int r;
	chnroute_list_t list;

	memset(&list, 0, sizeof(chnroute_list_t));

	dllist_init(&list.items);

	s = strdup(filename);

	for (p = strtok_r(s, ",", &saveptr);
		p && *p;
		p = strtok_r(NULL, ",", &saveptr)) {

		if (parse_chnroute_file(&list, p)) {
			free_chnroute_list(&list.items);
			free(s);
			return -1;
		}
	}

	free(s);

	r = feedback_net_list(ctx, &list);

	free_chnroute_list(&list.items);

	return r;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x268, %rsp            # imm = 0x268
leaq 0x48(%rsp), %rbx
andq $0x0, (%rbx)
leaq 0x18(%rsp), %rax
andq $0x0, 0x10(%rax)
movq %rdi, 0x10(%rsp)
movq %rax, (%rax)
movq %rax, 0x8(%rax)
movq %rsi, %rdi
callq 0x3620
leaq 0xf17d(%rip), %rsi      # 0x20878
movq %rax, 0x30(%rsp)
movq %rax, %rdi
movq %rbx, %rdx
callq 0x3610
movq %rax, %rbx
leaq 0x50(%rsp), %rbp
testq %rbx, %rbx
je 0x11ae7
cmpb $0x0, (%rbx)
je 0x11ae7
movq %rbx, %rdi
leaq 0xf08c(%rip), %rsi      # 0x207bb
callq 0x3440
testq %rax, %rax
je 0x11b97
movq %rax, %r12
movq %rax, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x3410
testl %eax, %eax
jne 0x11bd3
movq %rbx, 0x40(%rsp)
xorl %r13d, %r13d
leaq 0x60(%rsp), %rbx
movq %r12, 0x8(%rsp)
movq %rbx, %rdi
movl $0x200, %esi            # imm = 0x200
movq %r12, %rdx
callq 0x3590
testq %rax, %rax
je 0x11a1c
movq %rax, %r14
incl %r13d
cmpb $0x23, (%rax)
je 0x11766
movq %r14, %rdi
pushq $0xd
popq %rsi
callq 0x3150
testq %rax, %rax
je 0x1179d
movb $0x0, (%rax)
movq %r14, %rdi
pushq $0xa
popq %rsi
callq 0x3150
testq %rax, %rax
je 0x117b0
movb $0x0, (%rax)
cmpb $0x0, (%r14)
je 0x11766
pushq $0x1
popq %rdi
pushq $0x38
popq %rsi
callq 0x3250
testq %rax, %rax
je 0x11a3f
movq %rax, %r15
movq %r13, 0x38(%rsp)
movq %r14, %rdi
pushq $0x3a
popq %rsi
callq 0x3150
leaq 0x14(%r15), %r12
movq %r14, %rdi
pushq $0x2f
popq %rsi
testq %rax, %rax
je 0x1180b
callq 0x3150
movq %rax, %r13
testq %rax, %rax
je 0x11872
movb $0x0, (%r13)
leaq 0x1(%r13), %rdi
callq 0x3580
movl %eax, %ebx
jmp 0x11877
callq 0x3150
movq %rax, %r13
pushq $-0x1
popq %rbp
movl %ebp, %edx
testq %rax, %rax
je 0x11833
movb $0x0, (%r13)
leaq 0x1(%r13), %rdi
callq 0x3580
negb %al
movl %ebp, %edx
movl %eax, %ecx
shll %cl, %edx
movl %edx, 0x18(%r15)
pushq $0x2
popq %rdi
movq %r14, %rsi
leaq 0x50(%rsp), %rbp
movq %rbp, %rdx
callq 0x3640
testl %eax, %eax
je 0x119b4
xorl %eax, %eax
movl 0x50(%rsp), %ecx
bswapl %ecx
movl %ecx, (%r12)
testq %r13, %r13
je 0x11868
movb $0x2f, (%r13)
movq 0x8(%rsp), %r12
jmp 0x11975
movl $0x80, %ebx
pushq $0xa
popq %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0x3640
testl %eax, %eax
je 0x11905
movups 0x50(%rsp), %xmm0
movups %xmm0, (%r12)
xorl %eax, %eax
cmpq $0x4, %rax
je 0x118aa
movl (%r12,%rax,4), %ecx
bswapl %ecx
movl %ecx, (%r12,%rax,4)
incq %rax
jmp 0x11895
xorps %xmm0, %xmm0
movups %xmm0, 0x24(%r15)
movl %ebx, %eax
cltd
pushq $0x20
popq %rcx
idivl %ecx
movq %r15, %rsi
addq $0x24, %rsi
testl %eax, %eax
movl $0x0, %ecx
cmovgl %eax, %ecx
xorl %edi, %edi
movq 0x8(%rsp), %r12
leaq 0x60(%rsp), %rbx
cmpq %rdi, %rcx
je 0x118e5
orl $-0x1, (%rsi,%rdi,4)
incq %rdi
jmp 0x118d7
testl %edx, %edx
jle 0x118f7
negb %dl
pushq $-0x1
popq %rdi
movl %edx, %ecx
shll %cl, %edi
cltq
movl %edi, (%rsi,%rax,4)
xorl %eax, %eax
testq %r13, %r13
je 0x1196d
movb $0x2f, (%r13)
jmp 0x1196d
testq %r13, %r13
je 0x1190f
movb $0x2f, (%r13)
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
pushq $-0x1
popq %rax
movq 0x8(%rsp), %r12
leaq 0x60(%rsp), %rbx
jl 0x1196d
callq 0x3040
movl (%rax), %ebx
movl %ebx, %edi
callq 0x3140
movq %rax, %r10
pushq $0x3
popq %rdi
leaq 0xff33(%rip), %rsi      # 0x21876
leaq 0xff8a(%rip), %rdx      # 0x218d4
movl $0xdf, %ecx
leaq 0xff8d(%rip), %r8       # 0x218e3
movq %r14, %r9
xorl %eax, %eax
pushq %r10
pushq %rbx
leaq 0x70(%rsp), %rbx
callq 0x1662e
popq %rax
popq %rcx
pushq $-0x1
popq %rax
movl $0x1, 0x10(%r15)
movq 0x38(%rsp), %r13
testl %eax, %eax
jne 0x11a71
leaq 0x18(%rsp), %rax
movq %rax, (%r15)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%r15)
movq %r15, (%rax)
movq %r15, 0x20(%rsp)
cmpl $0x0, 0x10(%r15)
je 0x119ab
incl 0x2c(%rsp)
jmp 0x11766
incl 0x28(%rsp)
jmp 0x11766
testq %r13, %r13
movq 0x8(%rsp), %r12
je 0x119c3
movb $0x2f, (%r13)
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
pushq $-0x1
popq %rax
jl 0x11975
callq 0x3040
movl (%rax), %ebx
movl %ebx, %edi
callq 0x3140
movq %rax, %r10
pushq $0x3
popq %rdi
leaq 0xfe89(%rip), %rsi      # 0x21876
leaq 0xff0e(%rip), %rdx      # 0x21902
movl $0xc6, %ecx
leaq 0xff10(%rip), %r8       # 0x21910
movq %r14, %r9
xorl %eax, %eax
pushq %r10
pushq %rbx
leaq 0x70(%rsp), %rbx
callq 0x1662e
popq %rax
popq %rcx
pushq $-0x1
popq %rax
jmp 0x11975
movq %r12, %rdi
callq 0x3390
xorl %edi, %edi
leaq 0xee4b(%rip), %rsi      # 0x20878
leaq 0x48(%rsp), %rdx
callq 0x3610
movq %rax, %rbx
jmp 0x11713
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
jl 0x11ab4
leaq 0xfe24(%rip), %rsi      # 0x21876
leaq 0xfe2c(%rip), %rdx      # 0x21885
leaq 0xfe52(%rip), %r8       # 0x218b2
pushq $0x3
popq %rdi
movl $0x121, %ecx            # imm = 0x121
xorl %eax, %eax
callq 0x1662e
jmp 0x11ab4
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
jl 0x11aac
leaq 0xfdf2(%rip), %rsi      # 0x21876
leaq 0xfdfa(%rip), %rdx      # 0x21885
leaq 0xfe28(%rip), %r8       # 0x218ba
pushq $0x3
popq %rdi
movl $0x131, %ecx            # imm = 0x131
movq %r14, %r9
xorl %eax, %eax
pushq %r13
pushq 0x48(%rsp)
callq 0x1662e
popq %rax
popq %rcx
movq %r15, %rdi
callq 0x3460
movq %r12, %rdi
callq 0x3390
leaq 0x18(%rsp), %rdi
callq 0x11cbe
movq 0x30(%rsp), %rdi
callq 0x3460
pushq $-0x1
popq %rbx
movl %ebx, %eax
addq $0x268, %rsp            # imm = 0x268
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x30(%rsp), %rdi
callq 0x3460
movq 0x10(%rsp), %rbx
andl $0x0, (%rbx)
andl $0x0, 0x10(%rbx)
movslq 0x28(%rsp), %rdi
pushq $0x8
popq %rsi
callq 0x3250
movq %rax, 0x8(%rbx)
testq %rax, %rax
je 0x11c39
movslq 0x2c(%rsp), %rdi
pushq $0x20
popq %rsi
callq 0x3250
movq 0x10(%rsp), %r8
movq %rax, 0x18(%r8)
testq %rax, %rax
je 0x11c6e
movq 0x18(%rsp), %rdx
leaq 0x18(%rsp), %rax
cmpq %rax, %rdx
je 0x11c05
movq (%rdx), %rax
leaq 0x14(%rdx), %rcx
cmpl $0x0, 0x10(%rdx)
je 0x11b7e
movq 0x18(%r8), %rdx
movslq 0x10(%r8), %rsi
leal 0x1(%rsi), %edi
movl %edi, 0x10(%r8)
shlq $0x5, %rsi
movups (%rcx), %xmm0
movups 0x10(%rcx), %xmm1
movups %xmm1, 0x10(%rdx,%rsi)
movups %xmm0, (%rdx,%rsi)
movq %rax, %rdx
jmp 0x11b3b
movq 0x8(%r8), %rdx
movslq (%r8), %rsi
leal 0x1(%rsi), %edi
movl %edi, (%r8)
movq (%rcx), %rcx
movq %rcx, (%rdx,%rsi,8)
movq %rax, %rdx
jmp 0x11b3b
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
jl 0x11abc
leaq 0xfcc8(%rip), %rsi      # 0x21876
leaq 0xfcd0(%rip), %rdx      # 0x21885
leaq 0xfcdd(%rip), %r8       # 0x21899
pushq $0x3
popq %rdi
movl $0x106, %ecx            # imm = 0x106
movq %rbx, %r9
xorl %eax, %eax
callq 0x1662e
jmp 0x11abc
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
jl 0x11ab4
leaq 0xfc8c(%rip), %rsi      # 0x21876
leaq 0xfc94(%rip), %rdx      # 0x21885
leaq 0xfc0f(%rip), %r8       # 0x21807
pushq $0x3
popq %rdi
movl $0x10b, %ecx            # imm = 0x10B
jmp 0x11a68
movq 0x8(%r8), %rdi
movslq (%r8), %rsi
leaq -0x698(%rip), %rcx      # 0x1157b
pushq $0x8
popq %rdx
movq %r8, %rbx
callq 0x3650
movq 0x18(%rbx), %rdi
movslq 0x10(%rbx), %rsi
leaq -0x5cf(%rip), %rcx      # 0x1165e
pushq $0x20
popq %rdx
callq 0x3650
xorl %ebx, %ebx
jmp 0x11caf
xorl %eax, %eax
callq 0x165f5
pushq $-0x1
popq %rbx
cmpl $0x3, (%rax)
jl 0x11caf
leaq 0xfc27(%rip), %rsi      # 0x21876
leaq 0xfcda(%rip), %rdx      # 0x21930
leaq 0xfc55(%rip), %r8       # 0x218b2
pushq $0x3
popq %rdi
movl $0x14d, %ecx            # imm = 0x14D
xorl %eax, %eax
callq 0x1662e
jmp 0x11caf
xorl %eax, %eax
callq 0x165f5
cmpl $0x3, (%rax)
jl 0x11c9e
leaq 0xfbf5(%rip), %rsi      # 0x21876
leaq 0xfca8(%rip), %rdx      # 0x21930
leaq 0xfc23(%rip), %r8       # 0x218b2
pushq $0x3
popq %rdi
movl $0x153, %ecx            # imm = 0x153
xorl %eax, %eax
callq 0x1662e
movq 0x10(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x3460
pushq $-0x1
popq %rbx
leaq 0x18(%rsp), %rdi
callq 0x11cbe
jmp 0x11ad3