// File: /workspace/github_c_makefile_star2_O0/impact-eintr[P]st/st.c
// Function: strhandle
void
strhandle(void)
{
	char *p = NULL, *dec;
	int j, narg, par;

	term.esc &= ~(ESC_STR_END|ESC_STR);
	strparse();
	par = (narg = strescseq.narg) ? atoi(strescseq.args[0]) : 0;

	switch (strescseq.type) {
	case ']': /* OSC -- Operating System Command */
		switch (par) {
		case 0:
			if (narg > 1) {
				xsettitle(strescseq.args[1]);
				xseticontitle(strescseq.args[1]);
			}
			return;
		case 1:
			if (narg > 1)
				xseticontitle(strescseq.args[1]);
			return;
		case 2:
			if (narg > 1)
				xsettitle(strescseq.args[1]);
			return;
		case 52:
			if (narg > 2 && allowwindowops) {
				dec = base64dec(strescseq.args[2]);
				if (dec) {
					xsetsel(dec);
					xclipcopy();
				} else {
					fprintf(stderr, "erresc: invalid base64\n");
				}
			}
			return;
		case 4: /* color set */
			if (narg < 3)
				break;
			p = strescseq.args[2];
			/* FALLTHROUGH */
		case 104: /* color reset, here p = NULL */
			j = (narg > 1) ? atoi(strescseq.args[1]) : -1;
			if (xsetcolorname(j, p)) {
				if (par == 104 && narg <= 1)
					return; /* color reset without parameter */
				fprintf(stderr, "erresc: invalid color j=%d, p=%s\n",
				        j, p ? p : "(null)");
			} else {
				/*
				 * TODO if defaultbg color is changed, borders
				 * are dirty
				 */
				redraw();
			}
			return;
		}
		break;
	case 'k': /* old title set compatibility */
		xsettitle(strescseq.args[0]);
		return;
	case 'P': /* DCS -- Device Control String */
	case '_': /* APC -- Application Program Command */
	case '^': /* PM -- Privacy Message */
		return;
	}

	fprintf(stderr, "erresc: unknown str ");
	strdump();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq $0x0, -0x8(%rbp)
movl 0xfa2a(%rip), %eax      # 0x19df0
andl $-0x15, %eax
movl %eax, 0xfa21(%rip)      # 0x19df0
callq 0xa6a0
movl 0x11aee(%rip), %eax     # 0x1bec8
movl %eax, -0x18(%rbp)
cmpl $0x0, %eax
je 0xa3f3
movq 0x11a5f(%rip), %rdi     # 0x1be48
callq 0x54b0
movl %eax, -0x20(%rbp)
jmp 0xa3fa
xorl %eax, %eax
movl %eax, -0x20(%rbp)
jmp 0xa3fa
movl -0x20(%rbp), %eax
movl %eax, -0x1c(%rbp)
movsbl 0x11a21(%rip), %eax     # 0x1be28
addl $-0x50, %eax
movl %eax, %ecx
movq %rcx, -0x28(%rbp)
subl $0x1b, %eax
ja 0xa5e4
movq -0x28(%rbp), %rax
leaq 0x8110(%rip), %rcx      # 0x12534
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl -0x1c(%rbp), %eax
movl %eax, -0x2c(%rbp)
testl %eax, %eax
je 0xa476
jmp 0xa439
movl -0x2c(%rbp), %eax
subl $0x1, %eax
je 0xa499
jmp 0xa443
movl -0x2c(%rbp), %eax
subl $0x2, %eax
je 0xa4b0
jmp 0xa44d
movl -0x2c(%rbp), %eax
subl $0x4, %eax
je 0xa51f
jmp 0xa45b
movl -0x2c(%rbp), %eax
subl $0x34, %eax
je 0xa4c7
jmp 0xa465
movl -0x2c(%rbp), %eax
subl $0x68, %eax
je 0xa535
jmp 0xa5d2
cmpl $0x1, -0x18(%rbp)
jle 0xa494
movq 0x119cd(%rip), %rdi     # 0x1be50
callq 0xc6e0
movq 0x119c1(%rip), %rdi     # 0x1be50
callq 0xc640
jmp 0xa601
cmpl $0x1, -0x18(%rbp)
jle 0xa4ab
movq 0x119aa(%rip), %rdi     # 0x1be50
callq 0xc640
jmp 0xa601
cmpl $0x1, -0x18(%rbp)
jle 0xa4c2
movq 0x11993(%rip), %rdi     # 0x1be50
callq 0xc6e0
jmp 0xa601
cmpl $0x2, -0x18(%rbp)
jle 0xa51a
leaq 0x11ca4(%rip), %rax     # 0x1c178
cmpl $0x0, (%rax)
je 0xa51a
movq 0x11978(%rip), %rdi     # 0x1be58
callq 0xa760
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0xa500
movq -0x10(%rbp), %rdi
callq 0xbd90
callq 0xbd00
jmp 0xa518
movq 0xcae9(%rip), %rax      # 0x16ff0
movq (%rax), %rdi
leaq 0x8590(%rip), %rsi      # 0x12aa1
movb $0x0, %al
callq 0x5860
jmp 0xa51a
jmp 0xa601
cmpl $0x3, -0x18(%rbp)
jge 0xa52a
jmp 0xa5d2
movq 0x11927(%rip), %rax     # 0x1be58
movq %rax, -0x8(%rbp)
cmpl $0x1, -0x18(%rbp)
jle 0xa54c
movq 0x1190e(%rip), %rdi     # 0x1be50
callq 0x54b0
movl %eax, -0x30(%rbp)
jmp 0xa556
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %eax, -0x30(%rbp)
jmp 0xa556
movl -0x30(%rbp), %eax
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %edi
movq -0x8(%rbp), %rsi
callq 0xc150
cmpl $0x0, %eax
je 0xa5cb
cmpl $0x68, -0x1c(%rbp)
jne 0xa57e
cmpl $0x1, -0x18(%rbp)
jg 0xa57e
jmp 0xa601
movq 0xca6b(%rip), %rax      # 0x16ff0
movq (%rax), %rax
movq %rax, -0x40(%rbp)
movl -0x14(%rbp), %eax
movl %eax, -0x34(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0xa5a3
movq -0x8(%rbp), %rax
movq %rax, -0x48(%rbp)
jmp 0xa5b0
leaq 0x8531(%rip), %rax      # 0x12adb
movq %rax, -0x48(%rbp)
jmp 0xa5b0
movl -0x34(%rbp), %edx
movq -0x40(%rbp), %rdi
movq -0x48(%rbp), %rcx
leaq 0x84f7(%rip), %rsi      # 0x12ab9
movb $0x0, %al
callq 0x5860
jmp 0xa5d0
callq 0x8440
jmp 0xa601
jmp 0xa5e4
movq 0x1186d(%rip), %rdi     # 0x1be48
callq 0xc6e0
jmp 0xa601
jmp 0xa601
movq 0xca05(%rip), %rax      # 0x16ff0
movq (%rax), %rdi
leaq 0x84ed(%rip), %rsi      # 0x12ae2
movb $0x0, %al
callq 0x5860
callq 0xa8e0
addq $0x50, %rsp
popq %rbp
retq
nopw (%rax,%rax)