// File: /workspace/github_c_makefile_star2_O0/mmayer[P]pcal/src/pcalutil.c
// Function: define_font
void define_font (char *orig_font, char *new_font, char *dflt_font)
{
   char *ofont, *nfont, *osize, *nsize, tmp1[STRSIZ], tmp2[STRSIZ];

   /* use default font/size if new font is null */
   
   if (new_font == NULL || new_font[0] == '\0') {
      strcpy(orig_font, dflt_font);
      return;
   }
   
   /* split old and new fonts into font/size components */
   SPLIT(orig_font, ofont, osize, '/');
   
   new_font = strcpy(tmp1, new_font);
   SPLIT(new_font, nfont, nsize, '/');
   
   /* use default size if new font size invalid */
   if (nsize[0] && atoi(nsize) <= 0) nsize = strrchr(dflt_font, '/') + 1;
   
   /* replace fields of old font with specified fields from new */
   
   strcpy(tmp2, nfont[0] ? nfont : ofont);
   strcat(tmp2, "/");
   strcat(tmp2, nsize[0] ? nsize : osize);
   
   strcpy(orig_font, tmp2);

   return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x210, %rsp            # imm = 0x210
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0xb4aa
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0xb4bc
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x5080
jmp 0xb6bb
jmp 0xb4be
movq -0x8(%rbp), %rdi
movl $0x2f, %esi
callq 0x5130
movq %rax, -0x1d8(%rbp)
cmpq $0x0, %rax
je 0xb4fe
movq -0x1d8(%rbp), %rax
movb $0x0, (%rax)
movq -0x1d8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x1d8(%rbp)
movq %rax, -0x1e8(%rbp)
jmp 0xb50e
leaq 0x1a786(%rip), %rax     # 0x25c8b
movq %rax, -0x1e8(%rbp)
jmp 0xb50e
movq -0x1e8(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x20(%rbp)
movl $0x2f, %esi
callq 0x5100
movq %rax, -0x1d8(%rbp)
cmpq $0x0, %rax
je 0xb542
movq -0x1d8(%rbp), %rax
movb $0x0, (%rax)
jmp 0xb544
leaq -0x100(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x5080
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movl $0x2f, %esi
callq 0x5130
movq %rax, -0x1e0(%rbp)
cmpq $0x0, %rax
je 0xb598
movq -0x1e0(%rbp), %rax
movb $0x0, (%rax)
movq -0x1e0(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x1e0(%rbp)
movq %rax, -0x1f0(%rbp)
jmp 0xb5a8
leaq 0x1a6ec(%rip), %rax     # 0x25c8b
movq %rax, -0x1f0(%rbp)
jmp 0xb5a8
movq -0x1f0(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rdi
movq %rdi, -0x28(%rbp)
movl $0x2f, %esi
callq 0x5100
movq %rax, -0x1e0(%rbp)
cmpq $0x0, %rax
je 0xb5dc
movq -0x1e0(%rbp), %rax
movb $0x0, (%rax)
jmp 0xb5de
movq -0x38(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
je 0xb60e
movq -0x38(%rbp), %rdi
callq 0x5280
cmpl $0x0, %eax
jg 0xb60e
movq -0x18(%rbp), %rdi
movl $0x2f, %esi
callq 0x5130
addq $0x1, %rax
movq %rax, -0x38(%rbp)
leaq -0x1d0(%rbp), %rax
movq %rax, -0x1f8(%rbp)
movq -0x28(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
je 0xb635
movq -0x28(%rbp), %rax
movq %rax, -0x200(%rbp)
jmp 0xb640
movq -0x20(%rbp), %rax
movq %rax, -0x200(%rbp)
movq -0x1f8(%rbp), %rdi
movq -0x200(%rbp), %rsi
callq 0x5080
leaq -0x1d0(%rbp), %rdi
leaq 0x19008(%rip), %rsi     # 0x24669
callq 0x5290
leaq -0x1d0(%rbp), %rax
movq %rax, -0x208(%rbp)
movq -0x38(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
je 0xb68d
movq -0x38(%rbp), %rax
movq %rax, -0x210(%rbp)
jmp 0xb698
movq -0x30(%rbp), %rax
movq %rax, -0x210(%rbp)
movq -0x208(%rbp), %rdi
movq -0x210(%rbp), %rsi
callq 0x5290
movq -0x8(%rbp), %rdi
leaq -0x1d0(%rbp), %rsi
callq 0x5080
addq $0x210, %rsp            # imm = 0x210
popq %rbp
retq
nopw %cs:(%rax,%rax)