	.file	"351639.c"
	.intel_syntax noprefix
	.text
	.globl	usage
	.section	.rodata
	.align 8
.LC0:
	.string	"Usage: waitlock <timeout> <lock_file>\n"
	.section	.data.rel.ro.local,"aw"
	.align 8
	.type	usage, @object
	.size	usage, 8
usage:
	.quad	.LC0
	.text
	.type	alarm_handler, @function
alarm_handler:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	DWORD PTR -4[rbp], edi
	mov	edi, 2
	call	exit@PLT
	.cfi_endproc
.LFE6:
	.size	alarm_handler, .-alarm_handler
	.section	.rodata
	.align 8
.LC1:
	.string	"Usage: waitlock <timeout> <lock_file>"
.LC2:
	.string	"could not open file '%s': %s\n"
	.align 8
.LC3:
	.string	"the_stack_data/351639.c:%d: %s\n"
.LC4:
	.string	"could not lock file '%s': %s\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 224
	mov	DWORD PTR -212[rbp], edi
	mov	QWORD PTR -224[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -212[rbp], 3
	je	.L3
	lea	rdi, .LC1[rip]
	call	puts@PLT
	mov	eax, 1
	jmp	.L13
.L3:
	mov	rax, QWORD PTR -224[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rcx, -200[rbp]
	mov	edx, 10
	mov	rsi, rcx
	mov	rdi, rax
	call	strtoul@PLT
	mov	DWORD PTR -208[rbp], eax
	mov	rax, QWORD PTR -200[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	je	.L5
	lea	rdi, .LC1[rip]
	call	puts@PLT
	mov	eax, 1
	jmp	.L13
.L5:
	mov	rax, QWORD PTR -224[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	esi, 1
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -204[rbp], eax
	cmp	DWORD PTR -204[rbp], 0
	jns	.L6
	mov	rax, QWORD PTR -224[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	lea	rdx, -160[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	stat@PLT
	test	eax, eax
	jns	.L7
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	je	.L7
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rcx, rax
	mov	rax, QWORD PTR -224[rbp]
	add	rax, 16
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L13
.L7:
	mov	eax, 0
	jmp	.L13
.L6:
	lea	rax, alarm_handler[rip]
	mov	QWORD PTR -160[rbp], rax
	mov	DWORD PTR -24[rbp], 0
	lea	rax, -160[rbp]
	add	rax, 8
	mov	rdi, rax
	call	sigemptyset@PLT
	test	eax, eax
	jns	.L8
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rdx
	mov	edx, 58
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L8:
	lea	rax, -160[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 14
	call	sigaction@PLT
	test	eax, eax
	jns	.L9
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rdx
	mov	edx, 59
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L9:
	mov	eax, DWORD PTR -208[rbp]
	mov	edi, eax
	call	alarm@PLT
	mov	WORD PTR -192[rbp], 1
	mov	QWORD PTR -184[rbp], 0
	mov	WORD PTR -190[rbp], 0
	mov	QWORD PTR -176[rbp], 0
	lea	rdx, -192[rbp]
	mov	eax, DWORD PTR -204[rbp]
	mov	esi, 7
	mov	edi, eax
	mov	eax, 0
	call	fcntl@PLT
	test	eax, eax
	jns	.L10
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 13
	je	.L11
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 11
	jne	.L12
.L11:
	mov	eax, 1
	jmp	.L13
.L12:
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rcx, rax
	mov	rax, QWORD PTR -224[rbp]
	add	rax, 8
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L13
.L10:
	mov	eax, 0
.L13:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L14
	call	__stack_chk_fail@PLT
.L14:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"351639.c"
	.text
	.global	usage
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Usage: waitlock <timeout> <lock_file>\012\000"
	.align	2
	.type	usage, %object
	.size	usage, 4
usage:
	.word	.LC0
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	alarm_handler, %function
alarm_handler:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	mov	r0, #2
	bl	exit
	.size	alarm_handler, .-alarm_handler
	.section	.rodata
	.align	2
.LC1:
	.ascii	"Usage: waitlock <timeout> <lock_file>\000"
	.align	2
.LC2:
	.ascii	"could not open file '%s': %s\012\000"
	.align	2
.LC3:
	.ascii	"the_stack_data/351639.c:%d: %s\012\000"
	.align	2
.LC4:
	.ascii	"could not lock file '%s': %s\012\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 256
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #256
	str	r0, [fp, #-264]
	str	r1, [fp, #-268]
	ldr	r3, .L15
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	ldr	r3, [fp, #-264]
	cmp	r3, #3
	beq	.L3
	ldr	r0, .L15+4
	bl	puts
	mov	r3, #1
	b	.L13
.L3:
	ldr	r3, [fp, #-268]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r1, fp, #256
	mov	r2, #10
	mov	r0, r3
	bl	strtoul
	mov	r3, r0
	str	r3, [fp, #-252]
	ldr	r3, [fp, #-256]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L5
	ldr	r0, .L15+4
	bl	puts
	mov	r3, #1
	b	.L13
.L5:
	ldr	r3, [fp, #-268]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r1, #1
	mov	r0, r3
	bl	open
	str	r0, [fp, #-248]
	ldr	r3, [fp, #-248]
	cmp	r3, #0
	bge	.L6
	ldr	r3, [fp, #-268]
	add	r3, r3, #8
	ldr	r3, [r3]
	sub	r2, fp, #244
	mov	r1, r2
	mov	r0, r3
	bl	stat
	mov	r3, r0
	cmp	r3, #0
	bge	.L7
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #2
	beq	.L7
	ldr	r3, .L15+8
	ldr	r4, [r3]
	ldr	r3, [fp, #-268]
	add	r3, r3, #8
	ldr	r5, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r5
	ldr	r1, .L15+12
	mov	r0, r4
	bl	fprintf
	mov	r3, #1
	b	.L13
.L7:
	mov	r3, #0
	b	.L13
.L6:
	ldr	r3, .L15+16
	str	r3, [fp, #-156]
	mov	r3, #0
	str	r3, [fp, #-24]
	sub	r3, fp, #156
	add	r3, r3, #4
	mov	r0, r3
	bl	sigemptyset
	mov	r3, r0
	cmp	r3, #0
	bge	.L8
	ldr	r3, .L15+8
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, #58
	ldr	r1, .L15+20
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L8:
	sub	r3, fp, #156
	mov	r2, #0
	mov	r1, r3
	mov	r0, #14
	bl	sigaction
	mov	r3, r0
	cmp	r3, #0
	bge	.L9
	ldr	r3, .L15+8
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, #59
	ldr	r1, .L15+20
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L9:
	ldr	r3, [fp, #-252]
	mov	r0, r3
	bl	alarm
	mov	r3, #1
	strh	r3, [fp, #-244]	@ movhi
	mov	r3, #0
	str	r3, [fp, #-240]
	mov	r3, #0
	strh	r3, [fp, #-242]	@ movhi
	mov	r3, #0
	str	r3, [fp, #-236]
	sub	r3, fp, #244
	mov	r2, r3
	mov	r1, #7
	ldr	r0, [fp, #-248]
	bl	fcntl
	mov	r3, r0
	cmp	r3, #0
	bge	.L10
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #13
	beq	.L11
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #11
	bne	.L12
.L11:
	mov	r3, #1
	b	.L13
.L12:
	ldr	r3, .L15+8
	ldr	r4, [r3]
	ldr	r3, [fp, #-268]
	add	r3, r3, #4
	ldr	r5, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r5
	ldr	r1, .L15+24
	mov	r0, r4
	bl	fprintf
	mov	r3, #1
	b	.L13
.L10:
	mov	r3, #0
.L13:
	ldr	r2, .L15
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L14
	bl	__stack_chk_fail
.L14:
	mov	r0, r3
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L16:
	.align	2
.L15:
	.word	.LC5
	.word	.LC1
	.word	stderr
	.word	.LC2
	.word	alarm_handler
	.word	.LC3
	.word	.LC4
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
