	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function do_shell
_do_shell:                              ## @do_shell
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.4:
	callq	_system
	movl	%eax, %ebx
	cmpl	$127, %ebx
	jne	LBB0_6
	jmp	LBB0_7
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_getenv
	testq	%rax, %rax
	jne	LBB0_3
## %bb.2:
	movq	_DEFAULT_SHELL@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
LBB0_3:
	leaq	L_.str.1(%rip), %rdi
	movq	%rax, %rsi
	callq	_psprintf
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_system
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_free
	cmpl	$127, %ebx
	je	LBB0_7
LBB0_6:
	movl	$1, %eax
	cmpl	$-1, %ebx
	jne	LBB0_8
LBB0_7:
	leaq	L_.str.2(%rip), %rdi
	callq	_pg_log_error
	xorl	%eax, %eax
LBB0_8:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SHELL"

	.comm	_DEFAULT_SHELL,8,3              ## @DEFAULT_SHELL
L_.str.1:                               ## @.str.1
	.asciz	"exec %s"

L_.str.2:                               ## @.str.2
	.asciz	"\\!: failed"

	.no_dead_strip	_do_shell
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function do_shell
_do_shell:                              ; @do_shell
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	cbz	x0, LBB0_2
; %bb.1:
	bl	_system
	mov	x19, x0
	cmp	w19, #127
	b.ne	LBB0_3
	b	LBB0_4
LBB0_2:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_getenv
Lloh2:
	adrp	x8, _DEFAULT_SHELL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DEFAULT_SHELL@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	cmp	x0, #0
	csel	x1, x8, x0, eq
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_psprintf
	mov	x20, x0
	bl	_system
	mov	x19, x0
	mov	x0, x20
	bl	_free
	cmp	w19, #127
	b.eq	LBB0_4
LBB0_3:
	cmn	w19, #1
	b.ne	LBB0_5
LBB0_4:
Lloh7:
	adrp	x0, l_.str.2@PAGE
Lloh8:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pg_log_error
	mov	w0, #0
	b	LBB0_6
LBB0_5:
	mov	w0, #1
LBB0_6:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SHELL"

	.comm	_DEFAULT_SHELL,8,3              ; @DEFAULT_SHELL
l_.str.1:                               ; @.str.1
	.asciz	"exec %s"

l_.str.2:                               ; @.str.2
	.asciz	"\\!: failed"

	.no_dead_strip	_do_shell
.subsections_via_symbols
