// File: /workspace/github_c_makefile_star2_O2/hansvanstaveren[P]BigDeal/main.c
// Function: write_init_file
void
write_init_file(char *ifname)
/*
 * Prompt for defaults, and write init_file
 */
{
	FILE *ifile;
	char buf1[MESSLEN], buf2[MESSLEN];
	struct ifrecord *ifrp;

	printf("This program can generate various hand formats, one or more per run:\n\n");
	output_help();
	do {
		printf("Give comma separated list of formats usually desired: [%s] ",
			default_formats);
		readline(stdin, buf1, MESSLEN);
		if (buf1[0] == 0)
			strcpy(buf1, default_formats);
		strcpy(buf2, buf1);
	} while (output_specify_formats(buf2, 0)==0);
	strcpy(default_formats, buf1);

	printf("\nNormally you will always use the format(s) just specified,\n");
	printf("but maybe you would like to change it for some runs.\n");
	printf("Do you want the program to reconfirm the format every run? [%s] ", default_askformats);
	readline(stdin, buf1, MESSLEN);
	if (buf1[0])
		strcpy(default_askformats, buf1[0] == 'y' ? "yes" : "no");

	printf("\nIf you give an identification string the program will ensure\n");
	printf("that nobody with a different identification can generate the\n");
	printf("same sets of deals as you\n");
	printf("identication? [%s]\n? ", default_owner);
	readline(stdin, buf1, MESSLEN);
	if (buf1[0])
		strcpy(default_owner, buf1);

	ifile = fopen(ifname, "w");
	fprintf(ifile, "%s\n", init_header);
	for (ifrp=init_file; ifrp->if_keyword; ifrp++) {
		fprintf(ifile, "%s=%s\n", ifrp->if_keyword, ifrp->if_value);
	}
	fclose(ifile);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rdi, 0x8(%rsp)
leaq 0x27b0(%rip), %rdi      # 0x6281
callq 0x2060
callq 0x44c1
leaq 0x254f(%rip), %r14      # 0x6031
leaq 0x5627(%rip), %r15      # 0x9110
movq 0x54d8(%rip), %rbx      # 0x8fc8
leaq 0x10(%rsp), %r12
pushq $0x64
popq %rbp
leaq 0x80(%rsp), %r13
movq %r14, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x20c0
movq (%rbx), %rdi
movq %r12, %rsi
movl %ebp, %edx
callq 0x3c91
cmpb $0x0, 0x10(%rsp)
jne 0x3b2c
movq %r12, %rdi
movq %r15, %rsi
callq 0x2050
movq %r13, %rdi
movq %r12, %rsi
callq 0x2050
movq %r13, %rdi
xorl %esi, %esi
callq 0x452b
testl %eax, %eax
je 0x3b00
leaq 0x55c4(%rip), %rdi      # 0x9110
leaq 0x10(%rsp), %r14
movq %r14, %rsi
callq 0x2050
leaq 0x2767(%rip), %rdi      # 0x62c7
callq 0x2060
leaq 0x2797(%rip), %rdi      # 0x6303
callq 0x2060
leaq 0x24f5(%rip), %rdi      # 0x606d
leaq 0x5601(%rip), %rsi      # 0x9180
xorl %eax, %eax
callq 0x20c0
movq (%rbx), %rdi
pushq $0x64
popq %rdx
movq %r14, %rsi
callq 0x3c91
movb (%r14), %al
testb %al, %al
je 0x3bbb
cmpb $0x79, %al
leaq 0x250a(%rip), %rax      # 0x60ae
leaq 0x2507(%rip), %rsi      # 0x60b2
cmoveq %rax, %rsi
leaq 0x55ca(%rip), %rdi      # 0x9180
callq 0x2050
leaq 0x2776(%rip), %rdi      # 0x6338
callq 0x2060
leaq 0x27a8(%rip), %rdi      # 0x6376
callq 0x2060
leaq 0x27d9(%rip), %rdi      # 0x63b3
callq 0x2060
leaq 0x24cf(%rip), %rdi      # 0x60b5
leaq 0x5603(%rip), %rsi      # 0x91f0
xorl %eax, %eax
callq 0x20c0
movq (%rbx), %rdi
leaq 0x10(%rsp), %r14
pushq $0x64
popq %rdx
movq %r14, %rsi
callq 0x3c91
cmpb $0x0, (%r14)
je 0x3c1e
leaq 0x55dc(%rip), %rdi      # 0x91f0
leaq 0x10(%rsp), %rsi
callq 0x2050
leaq 0x2a73(%rip), %rsi      # 0x6698
movq 0x8(%rsp), %rdi
callq 0x2190
movq %rax, %rbx
leaq 0x2857(%rip), %rsi      # 0x6490
leaq 0x5660(%rip), %rdx      # 0x92a0
movq %rax, %rdi
xorl %eax, %eax
callq 0x2170
leaq 0x560f(%rip), %r15      # 0x9260
leaq 0x2473(%rip), %r14      # 0x60cb
movq (%r15), %rdx
testq %rdx, %rdx
je 0x3c77
movq 0x8(%r15), %rcx
movq %rbx, %rdi
movq %r14, %rsi
xorl %eax, %eax
callq 0x2170
addq $0x10, %r15
jmp 0x3c58
movq %rbx, %rdi
callq 0x2080
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq