	.file	"29826096.c"
	.intel_syntax noprefix
	.text
	.local	problems
	.comm	problems,4,4
	.section	.rodata
	.align 8
.LC0:
	.string	"cannot find name for group ID %u"
.LC1:
	.string	"%u"
.LC2:
	.string	"%s"
	.text
	.type	print_group, @function
print_group:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -8[rbp], 0
	mov	eax, DWORD PTR -20[rbp]
	mov	edi, eax
	call	getgrgid@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L2
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	warn@PLT
	mov	eax, DWORD PTR problems[rip]
	add	eax, 1
	mov	DWORD PTR problems[rip], eax
.L2:
	cmp	QWORD PTR -8[rbp], 0
	jne	.L3
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, eax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L5
.L3:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
.L5:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	print_group, .-print_group
	.section	.rodata
.LC3:
	.string	"out of memory"
	.align 8
.LC4:
	.string	"cannot get supplemental group list"
	.text
	.type	xgetgroups, @function
xgetgroups:
.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, 64
	mov	DWORD PTR -36[rbp], edi
	mov	QWORD PTR -48[rbp], rsi
	mov	QWORD PTR -56[rbp], rdx
	mov	DWORD PTR -20[rbp], 0
	mov	esi, 0
	mov	edi, 0
	call	getgroups@PLT
	mov	DWORD PTR -16[rbp], eax
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	sal	rax, 2
	add	rax, 1
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L7
	lea	rsi, .LC3[rip]
	mov	edi, 1
	mov	eax, 0
	call	err@PLT
.L7:
	mov	rdx, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR -16[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	getgroups@PLT
	mov	DWORD PTR -12[rbp], eax
	cmp	DWORD PTR -12[rbp], 0
	jns	.L8
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	warn@PLT
	add	DWORD PTR -20[rbp], 1
	mov	rax, QWORD PTR -56[rbp]
	mov	rdi, rax
	call	free@PLT
.L8:
	cmp	DWORD PTR -20[rbp], 0
	jne	.L9
	mov	rax, QWORD PTR -48[rbp]
	mov	edx, DWORD PTR -12[rbp]
	mov	DWORD PTR [rax], edx
	mov	rax, QWORD PTR -56[rbp]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR [rax], rdx
.L9:
	mov	eax, DWORD PTR -20[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	xgetgroups, .-xgetgroups
	.globl	main
	.type	main, @function
main:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r12
	push	rbx
	sub	rsp, 48
	.cfi_offset 12, -24
	.cfi_offset 3, -32
	mov	DWORD PTR -52[rbp], edi
	mov	QWORD PTR -64[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	call	getuid@PLT
	mov	edi, eax
	call	getpwuid@PLT
	mov	QWORD PTR -32[rbp], rax
	cmp	QWORD PTR -32[rbp], 0
	jne	.L12
	mov	eax, DWORD PTR problems[rip]
	add	eax, 1
	mov	DWORD PTR problems[rip], eax
.L12:
	call	getgid@PLT
	mov	edi, eax
	call	print_group
	call	getegid@PLT
	mov	ebx, eax
	call	getgid@PLT
	cmp	ebx, eax
	je	.L13
	mov	edi, 32
	call	putchar@PLT
	call	getegid@PLT
	mov	edi, eax
	call	print_group
.L13:
	mov	DWORD PTR -44[rbp], 0
	cmp	QWORD PTR -32[rbp], 0
	je	.L14
	mov	rax, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR 20[rax]
	jmp	.L15
.L14:
	mov	eax, -1
.L15:
	lea	rdx, -40[rbp]
	lea	rcx, -44[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	xgetgroups
	test	eax, eax
	je	.L16
	mov	eax, DWORD PTR problems[rip]
	add	eax, 1
	mov	DWORD PTR problems[rip], eax
	mov	eax, DWORD PTR problems[rip]
	jmp	.L17
.L16:
	mov	ebx, 0
	jmp	.L18
.L20:
	mov	rdx, QWORD PTR -40[rbp]
	movsx	rax, ebx
	sal	rax, 2
	add	rax, rdx
	mov	r12d, DWORD PTR [rax]
	call	getgid@PLT
	cmp	r12d, eax
	je	.L19
	mov	rdx, QWORD PTR -40[rbp]
	movsx	rax, ebx
	sal	rax, 2
	add	rax, rdx
	mov	r12d, DWORD PTR [rax]
	call	getegid@PLT
	cmp	r12d, eax
	je	.L19
	mov	edi, 32
	call	putchar@PLT
	mov	rdx, QWORD PTR -40[rbp]
	movsx	rax, ebx
	sal	rax, 2
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	print_group
.L19:
	add	ebx, 1
.L18:
	mov	eax, DWORD PTR -44[rbp]
	cmp	ebx, eax
	jl	.L20
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	edi, 10
	call	putchar@PLT
	mov	eax, DWORD PTR problems[rip]
	test	eax, eax
	setne	al
	movzx	eax, al
.L17:
	mov	rcx, QWORD PTR -24[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L21
	call	__stack_chk_fail@PLT
.L21:
	add	rsp, 48
	pop	rbx
	pop	r12
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.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	"29826096.c"
	.text
	.local	problems
	.comm	problems,4,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"cannot find name for group ID %u\000"
	.align	2
.LC1:
	.ascii	"%u\000"
	.align	2
.LC2:
	.ascii	"%s\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	print_group, %function
print_group:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	ldr	r0, [fp, #-16]
	bl	getgrgid
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L2
	ldr	r1, [fp, #-16]
	ldr	r0, .L6
	bl	warn
	ldr	r3, .L6+4
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L6+4
	str	r3, [r2]
.L2:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L3
	ldr	r1, [fp, #-16]
	ldr	r0, .L6+8
	bl	printf
	b	.L5
.L3:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L6+12
	bl	printf
.L5:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L7:
	.align	2
.L6:
	.word	.LC0
	.word	problems
	.word	.LC1
	.word	.LC2
	.size	print_group, .-print_group
	.section	.rodata
	.align	2
.LC3:
	.ascii	"out of memory\000"
	.align	2
.LC4:
	.ascii	"cannot get supplemental group list\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	xgetgroups, %function
xgetgroups:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-20]
	mov	r1, #0
	mov	r0, #0
	bl	getgroups
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #2
	add	r3, r3, #1
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L9
	ldr	r1, .L13
	mov	r0, #1
	bl	err
.L9:
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-16]
	bl	getgroups
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bge	.L10
	ldr	r0, .L13+4
	bl	warn
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
	ldr	r0, [fp, #-32]
	bl	free
.L10:
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L11
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-8]
	str	r2, [r3]
	ldr	r3, [fp, #-32]
	ldr	r2, [fp, #-12]
	str	r2, [r3]
.L11:
	ldr	r3, [fp, #-20]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	.LC3
	.word	.LC4
	.size	xgetgroups, .-xgetgroups
	.section	.rodata
	.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 = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #24
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	ldr	r3, .L26
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	bl	getuid
	mov	r3, r0
	mov	r0, r3
	bl	getpwuid
	str	r0, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L16
	ldr	r3, .L26+4
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L26+4
	str	r3, [r2]
.L16:
	bl	getgid
	mov	r3, r0
	mov	r0, r3
	bl	print_group
	bl	getegid
	mov	r4, r0
	bl	getgid
	mov	r3, r0
	cmp	r4, r3
	beq	.L17
	mov	r0, #32
	bl	putchar
	bl	getegid
	mov	r3, r0
	mov	r0, r3
	bl	print_group
.L17:
	mov	r3, #0
	str	r3, [fp, #-28]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	beq	.L18
	ldr	r3, [fp, #-20]
	ldr	r3, [r3, #12]
	b	.L19
.L18:
	mvn	r3, #0
.L19:
	sub	r2, fp, #24
	sub	r1, fp, #28
	mov	r0, r3
	bl	xgetgroups
	mov	r3, r0
	cmp	r3, #0
	beq	.L20
	ldr	r3, .L26+4
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L26+4
	str	r3, [r2]
	ldr	r3, .L26+4
	ldr	r3, [r3]
	b	.L21
.L20:
	mov	r4, #0
	b	.L22
.L24:
	ldr	r2, [fp, #-24]
	mov	r3, r4
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r5, [r3]
	bl	getgid
	mov	r3, r0
	cmp	r5, r3
	beq	.L23
	ldr	r2, [fp, #-24]
	mov	r3, r4
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r5, [r3]
	bl	getegid
	mov	r3, r0
	cmp	r5, r3
	beq	.L23
	mov	r0, #32
	bl	putchar
	ldr	r2, [fp, #-24]
	mov	r3, r4
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r0, r3
	bl	print_group
.L23:
	add	r4, r4, #1
.L22:
	ldr	r3, [fp, #-28]
	cmp	r4, r3
	blt	.L24
	ldr	r3, [fp, #-24]
	mov	r0, r3
	bl	free
	mov	r0, #10
	bl	putchar
	ldr	r3, .L26+4
	ldr	r3, [r3]
	cmp	r3, #0
	movne	r3, #1
	moveq	r3, #0
	and	r3, r3, #255
.L21:
	ldr	r2, .L26
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L25
	bl	__stack_chk_fail
.L25:
	mov	r0, r3
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L27:
	.align	2
.L26:
	.word	.LC5
	.word	problems
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
