	.file	"1226490.c"
	.intel_syntax noprefix
	.text
	.globl	error_count
	.bss
	.align 4
	.type	error_count, @object
	.size	error_count, 4
error_count:
	.zero	4
	.section	.rodata
.LC0:
	.string	"Call: %s returned NULL\n"
	.align 8
.LC1:
	.string	"Call: %s, returned: s_name: %s, s_port: %d, s_proto: %s\n"
.LC2:
	.string	"  alias: %s\n"
	.text
	.type	output_servent, @function
output_servent:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 40
	.cfi_offset 3, -24
	mov	QWORD PTR -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	cmp	QWORD PTR -48[rbp], 0
	jne	.L2
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L6
.L2:
	mov	rax, QWORD PTR -48[rbp]
	mov	rbx, QWORD PTR 24[rax]
	mov	rax, QWORD PTR -48[rbp]
	mov	eax, DWORD PTR 16[rax]
	movzx	eax, ax
	mov	edi, eax
	call	ntohs@PLT
	movzx	ecx, ax
	mov	rax, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -40[rbp]
	mov	r8, rbx
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -48[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -24[rbp], rax
	jmp	.L4
.L5:
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	add	QWORD PTR -24[rbp], 8
.L4:
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L5
.L6:
	nop
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	output_servent, .-output_servent
	.section	.rodata
.LC3:
	.string	"tcp"
.LC4:
	.string	"domain"
	.align 8
.LC5:
	.string	"getservbyname (\"domain\", \"tcp\")"
.LC6:
	.string	"udp"
	.align 8
.LC7:
	.string	"getservbyname (\"domain\", \"udp\")"
	.align 8
.LC8:
	.string	"getservbyname (\"domain\", NULL)"
.LC9:
	.string	"not-existant"
	.align 8
.LC10:
	.string	"getservbyname (\"not-existant\", NULL)"
.LC11:
	.string	""
.LC12:
	.string	"getservbyname (\"\", \"\")"
.LC13:
	.string	"getservbyname (\"\", \"tcp\")"
	.align 8
.LC14:
	.string	"getservbyport (htons(53), \"tcp\")"
	.align 8
.LC15:
	.string	"getservbyport (htons(53), NULL)"
	.align 8
.LC16:
	.string	"getservbyport (htons(1), \"udp\")"
.LC17:
	.string	"getservent ()"
	.text
	.type	test_services, @function
test_services:
.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, 16
	lea	rsi, .LC3[rip]
	lea	rdi, .LC4[rip]
	call	getservbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	call	output_servent
	lea	rsi, .LC6[rip]
	lea	rdi, .LC4[rip]
	call	getservbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC7[rip]
	call	output_servent
	mov	esi, 0
	lea	rdi, .LC4[rip]
	call	getservbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC8[rip]
	call	output_servent
	mov	esi, 0
	lea	rdi, .LC9[rip]
	call	getservbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC10[rip]
	call	output_servent
	lea	rsi, .LC11[rip]
	lea	rdi, .LC11[rip]
	call	getservbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC12[rip]
	call	output_servent
	lea	rsi, .LC3[rip]
	lea	rdi, .LC11[rip]
	call	getservbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC13[rip]
	call	output_servent
	mov	edi, 53
	call	htons@PLT
	movzx	eax, ax
	lea	rsi, .LC3[rip]
	mov	edi, eax
	call	getservbyport@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC14[rip]
	call	output_servent
	mov	edi, 53
	call	htons@PLT
	movzx	eax, ax
	mov	esi, 0
	mov	edi, eax
	call	getservbyport@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC15[rip]
	call	output_servent
	mov	edi, 1
	call	htons@PLT
	movzx	eax, ax
	lea	rsi, .LC6[rip]
	mov	edi, eax
	call	getservbyport@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC16[rip]
	call	output_servent
	mov	edi, 0
	call	setservent@PLT
.L8:
	call	getservent@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC17[rip]
	call	output_servent
	cmp	QWORD PTR -8[rbp], 0
	jne	.L8
	call	endservent@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	test_services, .-test_services
	.section	.rodata
	.align 8
.LC18:
	.string	"Call: %s returned: name: %s, addr_type: %d\n"
.LC19:
	.string	"  ip: %s\n"
	.text
	.type	output_hostent, @function
output_hostent:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 96
	mov	QWORD PTR -88[rbp], rdi
	mov	QWORD PTR -96[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	QWORD PTR -96[rbp], 0
	jne	.L10
	mov	rax, QWORD PTR -88[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L18
.L10:
	mov	rax, QWORD PTR -96[rbp]
	mov	ecx, DWORD PTR 16[rax]
	mov	rax, QWORD PTR -96[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -88[rbp]
	mov	rsi, rax
	lea	rdi, .LC18[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -96[rbp]
	mov	rax, QWORD PTR 8[rax]
	test	rax, rax
	je	.L12
	mov	rax, QWORD PTR -96[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -72[rbp], rax
	jmp	.L13
.L14:
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	add	QWORD PTR -72[rbp], 8
.L13:
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L14
.L12:
	mov	rax, QWORD PTR -96[rbp]
	mov	rax, QWORD PTR 24[rax]
	mov	QWORD PTR -72[rbp], rax
	jmp	.L15
.L16:
	mov	rax, QWORD PTR -72[rbp]
	mov	rsi, QWORD PTR [rax]
	mov	rax, QWORD PTR -96[rbp]
	mov	eax, DWORD PTR 16[rax]
	lea	rdx, -64[rbp]
	mov	ecx, 46
	mov	edi, eax
	call	inet_ntop@PLT
	mov	rsi, rax
	lea	rdi, .LC19[rip]
	mov	eax, 0
	call	printf@PLT
	add	QWORD PTR -72[rbp], 8
.L15:
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L16
.L18:
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	output_hostent, .-output_hostent
	.section	.rodata
.LC20:
	.string	"localhost"
.LC21:
	.string	"LocalHost"
	.align 8
.LC22:
	.string	"localhost not found - but LocalHost found:-("
	.align 8
.LC23:
	.string	"LocalHost not found - but localhost found:-("
	.align 8
.LC24:
	.string	"localhost and LocalHost have different canoncial name"
	.align 8
.LC25:
	.string	"gethostbyname (\"localhost\")->%s\n"
	.align 8
.LC26:
	.string	"gethostbyname (\"LocalHost\")->%s\n"
.LC27:
	.string	"gethostbyname(\"localhost\")"
.LC28:
	.string	"127.0.0.1"
.LC29:
	.string	"gethostbyname (\"127.0.0.1\")"
.LC30:
	.string	"10.1234"
.LC31:
	.string	"gethostbyname (\"10.1234\")"
	.align 8
.LC32:
	.string	"gethostbyname2 (\"localhost\", AF_INET)"
.LC33:
	.string	"Hostname: %s\n"
	.align 8
.LC34:
	.string	"gethostbyname (gethostname(...))"
	.align 8
.LC35:
	.string	"official name of 127.0.0.1: %s\n"
.LC36:
	.string	"gethostent ()"
	.text
	.type	test_hosts, @function
test_hosts:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 48
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -40[rbp], 0
	mov	QWORD PTR -32[rbp], 0
	lea	rdi, .LC20[rip]
	call	gethostbyname@PLT
	mov	QWORD PTR -24[rbp], rax
	lea	rdi, .LC21[rip]
	call	gethostbyname@PLT
	mov	QWORD PTR -16[rbp], rax
	cmp	QWORD PTR -24[rbp], 0
	jne	.L20
	cmp	QWORD PTR -16[rbp], 0
	je	.L21
.L20:
	cmp	QWORD PTR -24[rbp], 0
	jne	.L22
	lea	rdi, .LC22[rip]
	call	puts@PLT
	mov	eax, DWORD PTR error_count[rip]
	add	eax, 1
	mov	DWORD PTR error_count[rip], eax
	jmp	.L21
.L22:
	cmp	QWORD PTR -16[rbp], 0
	jne	.L23
	lea	rdi, .LC23[rip]
	call	puts@PLT
	mov	eax, DWORD PTR error_count[rip]
	add	eax, 1
	mov	DWORD PTR error_count[rip], eax
	jmp	.L21
.L23:
	mov	rax, QWORD PTR -16[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	je	.L24
	lea	rdi, .LC24[rip]
	call	puts@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC25[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC26[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR error_count[rip]
	add	eax, 1
	mov	DWORD PTR error_count[rip], eax
	jmp	.L21
.L24:
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC27[rip]
	call	output_hostent
.L21:
	lea	rdi, .LC28[rip]
	call	gethostbyname@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC29[rip]
	call	output_hostent
	lea	rdi, .LC30[rip]
	call	gethostbyname@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC31[rip]
	call	output_hostent
	mov	esi, 2
	lea	rdi, .LC20[rip]
	call	gethostbyname2@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC32[rip]
	call	output_hostent
	jmp	.L25
.L27:
	add	QWORD PTR -32[rbp], 2
	mov	rdx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	realloc@PLT
	mov	QWORD PTR -40[rbp], rax
.L25:
	mov	rdx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	gethostname@PLT
	test	eax, eax
	jns	.L26
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 36
	je	.L27
.L26:
	mov	rdx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	gethostname@PLT
	test	eax, eax
	jne	.L28
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC33[rip]
	mov	eax, 0
	call	printf@PLT
	cmp	QWORD PTR -40[rbp], 0
	je	.L28
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	gethostbyname@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC34[rip]
	call	output_hostent
.L28:
	mov	edi, 2130706433
	call	htonl@PLT
	mov	DWORD PTR -44[rbp], eax
	lea	rax, -44[rbp]
	mov	edx, 2
	mov	esi, 4
	mov	rdi, rax
	call	gethostbyaddr@PLT
	mov	QWORD PTR -24[rbp], rax
	cmp	QWORD PTR -24[rbp], 0
	je	.L29
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC35[rip]
	mov	eax, 0
	call	printf@PLT
.L29:
	mov	edi, 0
	call	sethostent@PLT
.L30:
	call	gethostent@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC36[rip]
	call	output_hostent
	cmp	QWORD PTR -24[rbp], 0
	jne	.L30
	call	endhostent@PLT
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L31
	call	__stack_chk_fail@PLT
.L31:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	test_hosts, .-test_hosts
	.section	.rodata
	.align 8
.LC37:
	.string	"Call: %s, returned: n_name: %s, network_number: %s\n"
	.text
	.type	output_netent, @function
output_netent:
.LFB10:
	.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	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	cmp	QWORD PTR -32[rbp], 0
	jne	.L33
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L37
.L33:
	mov	rax, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR 20[rax]
	mov	edi, eax
	call	htonl@PLT
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -12[rbp]
	mov	edi, eax
	call	inet_ntoa@PLT
	mov	rcx, rax
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC37[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -8[rbp], rax
	jmp	.L35
.L36:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	add	QWORD PTR -8[rbp], 8
.L35:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L36
.L37:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	output_netent, .-output_netent
	.section	.rodata
.LC38:
	.string	"loopback"
.LC39:
	.string	"getnetbyname (\"loopback\")"
.LC40:
	.string	"LoopBACK"
.LC41:
	.string	"getnetbyname (\"LoopBACK\")"
.LC42:
	.string	"127.0.0.0"
	.align 8
.LC43:
	.string	"getnetbyaddr (inet_network (\"127.0.0.0\"), AF_INET)"
.LC44:
	.string	"getnetent ()"
	.text
	.type	test_network, @function
test_network:
.LFB11:
	.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
	lea	rdi, .LC38[rip]
	call	getnetbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC39[rip]
	call	output_netent
	lea	rdi, .LC40[rip]
	call	getnetbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC41[rip]
	call	output_netent
	lea	rdi, .LC42[rip]
	call	inet_network@PLT
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -12[rbp]
	mov	esi, 2
	mov	edi, eax
	call	getnetbyaddr@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC43[rip]
	call	output_netent
	mov	edi, 0
	call	setnetent@PLT
.L39:
	call	getnetent@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC44[rip]
	call	output_netent
	cmp	QWORD PTR -8[rbp], 0
	jne	.L39
	call	endnetent@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	test_network, .-test_network
	.section	.rodata
	.align 8
.LC45:
	.string	"Call: %s, returned: p_name: %s, p_proto: %d\n"
	.text
	.type	output_protoent, @function
output_protoent:
.LFB12:
	.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	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	cmp	QWORD PTR -32[rbp], 0
	jne	.L41
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L45
.L41:
	mov	rax, QWORD PTR -32[rbp]
	mov	ecx, DWORD PTR 16[rax]
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC45[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -8[rbp], rax
	jmp	.L43
.L44:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	add	QWORD PTR -8[rbp], 8
.L43:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L44
.L45:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	output_protoent, .-output_protoent
	.section	.rodata
.LC46:
	.string	"IP"
.LC47:
	.string	"getprotobyname (\"IP\")"
.LC48:
	.string	"getprotobynumber (1)"
.LC49:
	.string	"getprotoent ()"
	.text
	.type	test_protocols, @function
test_protocols:
.LFB13:
	.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
	lea	rdi, .LC46[rip]
	call	getprotobyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC47[rip]
	call	output_protoent
	mov	edi, 1
	call	getprotobynumber@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC48[rip]
	call	output_protoent
	mov	edi, 0
	call	setprotoent@PLT
.L47:
	call	getprotoent@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC49[rip]
	call	output_protoent
	cmp	QWORD PTR -8[rbp], 0
	jne	.L47
	call	endprotoent@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	test_protocols, .-test_protocols
	.section	.rodata
	.align 8
.LC50:
	.string	"Call: %s, returned: r_name: %s, r_number: %d\n"
	.text
	.type	output_rpcent, @function
output_rpcent:
.LFB14:
	.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	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	cmp	QWORD PTR -32[rbp], 0
	jne	.L49
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L53
.L49:
	mov	rax, QWORD PTR -32[rbp]
	mov	ecx, DWORD PTR 16[rax]
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC50[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -8[rbp], rax
	jmp	.L51
.L52:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	add	QWORD PTR -8[rbp], 8
.L51:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L52
.L53:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	output_rpcent, .-output_rpcent
	.section	.rodata
.LC51:
	.string	"portmap"
.LC52:
	.string	"getrpcyname (\"portmap\")"
.LC53:
	.string	"getrpcbynumber (100000)"
.LC54:
	.string	"getrpcent ()"
	.text
	.type	test_rpc, @function
test_rpc:
.LFB15:
	.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
	lea	rdi, .LC51[rip]
	call	getrpcbyname@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC52[rip]
	call	output_rpcent
	mov	edi, 100000
	call	getrpcbynumber@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC53[rip]
	call	output_rpcent
	mov	edi, 0
	call	setrpcent@PLT
.L55:
	call	getrpcent@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC54[rip]
	call	output_rpcent
	cmp	QWORD PTR -8[rbp], 0
	jne	.L55
	call	endrpcent@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	test_rpc, .-test_rpc
	.section	.rodata
.LC55:
	.string	"db"
.LC56:
	.string	"hosts"
.LC57:
	.string	"networks"
.LC58:
	.string	"protocols"
.LC59:
	.string	"rpc"
.LC60:
	.string	"services"
	.text
	.type	setdb, @function
setdb:
.LFB16:
	.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	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC55[rip]
	call	strcmp@PLT
	test	eax, eax
	je	.L57
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC56[rip]
	call	__nss_configure_lookup@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC57[rip]
	call	__nss_configure_lookup@PLT
.L57:
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC58[rip]
	call	__nss_configure_lookup@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC59[rip]
	call	__nss_configure_lookup@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC60[rip]
	call	__nss_configure_lookup@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE16:
	.size	setdb, .-setdb
	.section	.rodata
.LC61:
	.string	"\n %d errors occurred!\n"
.LC62:
	.string	"No visible errors occurred!"
	.text
	.globl	main
	.type	main, @function
main:
.LFB17:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	call	test_hosts
	call	test_network
	call	test_protocols
	call	test_rpc
	call	test_services
	mov	eax, DWORD PTR error_count[rip]
	test	eax, eax
	je	.L59
	mov	eax, DWORD PTR error_count[rip]
	mov	esi, eax
	lea	rdi, .LC61[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L60
.L59:
	lea	rdi, .LC62[rip]
	call	puts@PLT
.L60:
	mov	eax, DWORD PTR error_count[rip]
	test	eax, eax
	setne	al
	movzx	eax, al
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE17:
	.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	"1226490.c"
	.text
	.comm	error_count,4,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Call: %s returned NULL\012\000"
	.align	2
.LC1:
	.ascii	"Call: %s, returned: s_name: %s, s_port: %d, s_proto"
	.ascii	": %s\012\000"
	.align	2
.LC2:
	.ascii	"  alias: %s\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	output_servent, %function
output_servent:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L2
	ldr	r1, [fp, #-24]
	ldr	r0, .L7
	bl	printf
	b	.L6
.L2:
	ldr	r3, [fp, #-28]
	ldr	r4, [r3]
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #8]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	mov	r0, r3
	bl	ntohs
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #12]
	str	r3, [sp]
	mov	r3, r2
	mov	r2, r4
	ldr	r1, [fp, #-24]
	ldr	r0, .L7+4
	bl	printf
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-16]
	b	.L4
.L5:
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L7+8
	bl	printf
	ldr	r3, [fp, #-16]
	add	r3, r3, #4
	str	r3, [fp, #-16]
.L4:
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L5
.L6:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L8:
	.align	2
.L7:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.size	output_servent, .-output_servent
	.section	.rodata
	.align	2
.LC3:
	.ascii	"tcp\000"
	.align	2
.LC4:
	.ascii	"domain\000"
	.align	2
.LC5:
	.ascii	"getservbyname (\"domain\", \"tcp\")\000"
	.align	2
.LC6:
	.ascii	"udp\000"
	.align	2
.LC7:
	.ascii	"getservbyname (\"domain\", \"udp\")\000"
	.align	2
.LC8:
	.ascii	"getservbyname (\"domain\", NULL)\000"
	.align	2
.LC9:
	.ascii	"not-existant\000"
	.align	2
.LC10:
	.ascii	"getservbyname (\"not-existant\", NULL)\000"
	.align	2
.LC11:
	.ascii	"\000"
	.align	2
.LC12:
	.ascii	"getservbyname (\"\", \"\")\000"
	.align	2
.LC13:
	.ascii	"getservbyname (\"\", \"tcp\")\000"
	.align	2
.LC14:
	.ascii	"getservbyport (htons(53), \"tcp\")\000"
	.align	2
.LC15:
	.ascii	"getservbyport (htons(53), NULL)\000"
	.align	2
.LC16:
	.ascii	"getservbyport (htons(1), \"udp\")\000"
	.align	2
.LC17:
	.ascii	"getservent ()\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	test_services, %function
test_services:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r1, .L11
	ldr	r0, .L11+4
	bl	getservbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+8
	bl	output_servent
	ldr	r1, .L11+12
	ldr	r0, .L11+4
	bl	getservbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+16
	bl	output_servent
	mov	r1, #0
	ldr	r0, .L11+4
	bl	getservbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+20
	bl	output_servent
	mov	r1, #0
	ldr	r0, .L11+24
	bl	getservbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+28
	bl	output_servent
	ldr	r1, .L11+32
	ldr	r0, .L11+32
	bl	getservbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+36
	bl	output_servent
	ldr	r1, .L11
	ldr	r0, .L11+32
	bl	getservbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+40
	bl	output_servent
	mov	r0, #53
	bl	htons
	mov	r3, r0
	ldr	r1, .L11
	mov	r0, r3
	bl	getservbyport
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+44
	bl	output_servent
	mov	r0, #53
	bl	htons
	mov	r3, r0
	mov	r1, #0
	mov	r0, r3
	bl	getservbyport
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+48
	bl	output_servent
	mov	r0, #1
	bl	htons
	mov	r3, r0
	ldr	r1, .L11+12
	mov	r0, r3
	bl	getservbyport
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+52
	bl	output_servent
	mov	r0, #0
	bl	setservent
.L10:
	bl	getservent
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L11+56
	bl	output_servent
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L10
	bl	endservent
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L12:
	.align	2
.L11:
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.word	.LC16
	.word	.LC17
	.size	test_services, .-test_services
	.section	.rodata
	.align	2
.LC18:
	.ascii	"Call: %s returned: name: %s, addr_type: %d\012\000"
	.align	2
.LC19:
	.ascii	"  ip: %s\012\000"
	.align	2
.LC20:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	output_hostent, %function
output_hostent:
	@ args = 0, pretend = 0, frame = 64
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #64
	str	r0, [fp, #-64]
	str	r1, [fp, #-68]
	ldr	r3, .L23
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-68]
	cmp	r3, #0
	bne	.L14
	ldr	r1, [fp, #-64]
	ldr	r0, .L23+4
	bl	printf
	b	.L22
.L14:
	ldr	r3, [fp, #-68]
	ldr	r2, [r3]
	ldr	r3, [fp, #-68]
	ldr	r3, [r3, #8]
	ldr	r1, [fp, #-64]
	ldr	r0, .L23+8
	bl	printf
	ldr	r3, [fp, #-68]
	ldr	r3, [r3, #4]
	cmp	r3, #0
	beq	.L16
	ldr	r3, [fp, #-68]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-60]
	b	.L17
.L18:
	ldr	r3, [fp, #-60]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L23+12
	bl	printf
	ldr	r3, [fp, #-60]
	add	r3, r3, #4
	str	r3, [fp, #-60]
.L17:
	ldr	r3, [fp, #-60]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L18
.L16:
	ldr	r3, [fp, #-68]
	ldr	r3, [r3, #16]
	str	r3, [fp, #-60]
	b	.L19
.L20:
	ldr	r3, [fp, #-68]
	ldr	r0, [r3, #8]
	ldr	r3, [fp, #-60]
	ldr	r1, [r3]
	sub	r2, fp, #56
	mov	r3, #46
	bl	inet_ntop
	mov	r3, r0
	mov	r1, r3
	ldr	r0, .L23+16
	bl	printf
	ldr	r3, [fp, #-60]
	add	r3, r3, #4
	str	r3, [fp, #-60]
.L19:
	ldr	r3, [fp, #-60]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L20
.L22:
	nop
	ldr	r3, .L23
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L21
	bl	__stack_chk_fail
.L21:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L24:
	.align	2
.L23:
	.word	.LC20
	.word	.LC0
	.word	.LC18
	.word	.LC2
	.word	.LC19
	.size	output_hostent, .-output_hostent
	.section	.rodata
	.align	2
.LC21:
	.ascii	"localhost\000"
	.align	2
.LC22:
	.ascii	"LocalHost\000"
	.align	2
.LC23:
	.ascii	"localhost not found - but LocalHost found:-(\000"
	.align	2
.LC24:
	.ascii	"LocalHost not found - but localhost found:-(\000"
	.align	2
.LC25:
	.ascii	"localhost and LocalHost have different canoncial na"
	.ascii	"me\000"
	.align	2
.LC26:
	.ascii	"gethostbyname (\"localhost\")->%s\012\000"
	.align	2
.LC27:
	.ascii	"gethostbyname (\"LocalHost\")->%s\012\000"
	.align	2
.LC28:
	.ascii	"gethostbyname(\"localhost\")\000"
	.align	2
.LC29:
	.ascii	"127.0.0.1\000"
	.align	2
.LC30:
	.ascii	"gethostbyname (\"127.0.0.1\")\000"
	.align	2
.LC31:
	.ascii	"10.1234\000"
	.align	2
.LC32:
	.ascii	"gethostbyname (\"10.1234\")\000"
	.align	2
.LC33:
	.ascii	"gethostbyname2 (\"localhost\", AF_INET)\000"
	.align	2
.LC34:
	.ascii	"Hostname: %s\012\000"
	.align	2
.LC35:
	.ascii	"gethostbyname (gethostname(...))\000"
	.align	2
.LC36:
	.ascii	"official name of 127.0.0.1: %s\012\000"
	.align	2
.LC37:
	.ascii	"gethostent ()\000"
	.align	2
.LC38:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	test_hosts, %function
test_hosts:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	ldr	r3, .L38
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-24]
	mov	r3, #0
	str	r3, [fp, #-20]
	ldr	r0, .L38+4
	bl	gethostbyname
	str	r0, [fp, #-16]
	ldr	r0, .L38+8
	bl	gethostbyname
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L26
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L27
.L26:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L28
	ldr	r0, .L38+12
	bl	puts
	ldr	r3, .L38+16
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L38+16
	str	r3, [r2]
	b	.L27
.L28:
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L29
	ldr	r0, .L38+20
	bl	puts
	ldr	r3, .L38+16
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L38+16
	str	r3, [r2]
	b	.L27
.L29:
	ldr	r3, [fp, #-16]
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	ldr	r3, [r3]
	mov	r1, r3
	mov	r0, r2
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L30
	ldr	r0, .L38+24
	bl	puts
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L38+28
	bl	printf
	ldr	r3, [fp, #-12]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L38+32
	bl	printf
	ldr	r3, .L38+16
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L38+16
	str	r3, [r2]
	b	.L27
.L30:
	ldr	r1, [fp, #-16]
	ldr	r0, .L38+36
	bl	output_hostent
.L27:
	ldr	r0, .L38+40
	bl	gethostbyname
	str	r0, [fp, #-16]
	ldr	r1, [fp, #-16]
	ldr	r0, .L38+44
	bl	output_hostent
	ldr	r0, .L38+48
	bl	gethostbyname
	str	r0, [fp, #-16]
	ldr	r1, [fp, #-16]
	ldr	r0, .L38+52
	bl	output_hostent
	mov	r1, #2
	ldr	r0, .L38+4
	bl	gethostbyname2
	str	r0, [fp, #-16]
	ldr	r1, [fp, #-16]
	ldr	r0, .L38+56
	bl	output_hostent
	b	.L31
.L33:
	ldr	r3, [fp, #-20]
	add	r3, r3, #2
	str	r3, [fp, #-20]
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-24]
	bl	realloc
	str	r0, [fp, #-24]
.L31:
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-24]
	bl	gethostname
	mov	r3, r0
	cmp	r3, #0
	bge	.L32
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #36
	beq	.L33
.L32:
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-24]
	bl	gethostname
	mov	r3, r0
	cmp	r3, #0
	bne	.L34
	ldr	r1, [fp, #-24]
	ldr	r0, .L38+60
	bl	printf
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	beq	.L34
	ldr	r0, [fp, #-24]
	bl	gethostbyname
	str	r0, [fp, #-16]
	ldr	r1, [fp, #-16]
	ldr	r0, .L38+64
	bl	output_hostent
.L34:
	ldr	r0, .L38+68
	bl	htonl
	mov	r3, r0
	str	r3, [fp, #-28]
	sub	r3, fp, #28
	mov	r2, #2
	mov	r1, #4
	mov	r0, r3
	bl	gethostbyaddr
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	beq	.L35
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L38+72
	bl	printf
.L35:
	mov	r0, #0
	bl	sethostent
.L36:
	bl	gethostent
	str	r0, [fp, #-16]
	ldr	r1, [fp, #-16]
	ldr	r0, .L38+76
	bl	output_hostent
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L36
	bl	endhostent
	nop
	ldr	r3, .L38
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L37
	bl	__stack_chk_fail
.L37:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L39:
	.align	2
.L38:
	.word	.LC38
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.word	error_count
	.word	.LC24
	.word	.LC25
	.word	.LC26
	.word	.LC27
	.word	.LC28
	.word	.LC29
	.word	.LC30
	.word	.LC31
	.word	.LC32
	.word	.LC33
	.word	.LC34
	.word	.LC35
	.word	2130706433
	.word	.LC36
	.word	.LC37
	.size	test_hosts, .-test_hosts
	.section	.rodata
	.align	2
.LC39:
	.ascii	"Call: %s, returned: n_name: %s, network_number: %s\012"
	.ascii	"\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	output_netent, %function
output_netent:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L41
	ldr	r1, [fp, #-24]
	ldr	r0, .L46
	bl	printf
	b	.L45
.L41:
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #12]
	mov	r0, r3
	bl	htonl
	mov	r3, r0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-28]
	ldr	r4, [r3]
	ldr	r0, [fp, #-20]
	bl	inet_ntoa
	mov	r3, r0
	mov	r2, r4
	ldr	r1, [fp, #-24]
	ldr	r0, .L46+4
	bl	printf
	ldr	r3, [fp, #-28]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-16]
	b	.L43
.L44:
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L46+8
	bl	printf
	ldr	r3, [fp, #-16]
	add	r3, r3, #4
	str	r3, [fp, #-16]
.L43:
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L44
.L45:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L47:
	.align	2
.L46:
	.word	.LC0
	.word	.LC39
	.word	.LC2
	.size	output_netent, .-output_netent
	.section	.rodata
	.align	2
.LC40:
	.ascii	"loopback\000"
	.align	2
.LC41:
	.ascii	"getnetbyname (\"loopback\")\000"
	.align	2
.LC42:
	.ascii	"LoopBACK\000"
	.align	2
.LC43:
	.ascii	"getnetbyname (\"LoopBACK\")\000"
	.align	2
.LC44:
	.ascii	"127.0.0.0\000"
	.align	2
.LC45:
	.ascii	"getnetbyaddr (inet_network (\"127.0.0.0\"), AF_INET"
	.ascii	")\000"
	.align	2
.LC46:
	.ascii	"getnetent ()\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	test_network, %function
test_network:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r0, .L50
	bl	getnetbyname
	str	r0, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, .L50+4
	bl	output_netent
	ldr	r0, .L50+8
	bl	getnetbyname
	str	r0, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, .L50+12
	bl	output_netent
	ldr	r0, .L50+16
	bl	inet_network
	str	r0, [fp, #-8]
	mov	r1, #2
	ldr	r0, [fp, #-8]
	bl	getnetbyaddr
	str	r0, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, .L50+20
	bl	output_netent
	mov	r0, #0
	bl	setnetent
.L49:
	bl	getnetent
	str	r0, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, .L50+24
	bl	output_netent
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L49
	bl	endnetent
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L51:
	.align	2
.L50:
	.word	.LC40
	.word	.LC41
	.word	.LC42
	.word	.LC43
	.word	.LC44
	.word	.LC45
	.word	.LC46
	.size	test_network, .-test_network
	.section	.rodata
	.align	2
.LC47:
	.ascii	"Call: %s, returned: p_name: %s, p_proto: %d\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	output_protoent, %function
output_protoent:
	@ 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]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L53
	ldr	r1, [fp, #-16]
	ldr	r0, .L58
	bl	printf
	b	.L57
.L53:
	ldr	r3, [fp, #-20]
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	ldr	r3, [r3, #8]
	ldr	r1, [fp, #-16]
	ldr	r0, .L58+4
	bl	printf
	ldr	r3, [fp, #-20]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-8]
	b	.L55
.L56:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L58+8
	bl	printf
	ldr	r3, [fp, #-8]
	add	r3, r3, #4
	str	r3, [fp, #-8]
.L55:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L56
.L57:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L59:
	.align	2
.L58:
	.word	.LC0
	.word	.LC47
	.word	.LC2
	.size	output_protoent, .-output_protoent
	.section	.rodata
	.align	2
.LC48:
	.ascii	"IP\000"
	.align	2
.LC49:
	.ascii	"getprotobyname (\"IP\")\000"
	.align	2
.LC50:
	.ascii	"getprotobynumber (1)\000"
	.align	2
.LC51:
	.ascii	"getprotoent ()\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	test_protocols, %function
test_protocols:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r0, .L62
	bl	getprotobyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L62+4
	bl	output_protoent
	mov	r0, #1
	bl	getprotobynumber
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L62+8
	bl	output_protoent
	mov	r0, #0
	bl	setprotoent
.L61:
	bl	getprotoent
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L62+12
	bl	output_protoent
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L61
	bl	endprotoent
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L63:
	.align	2
.L62:
	.word	.LC48
	.word	.LC49
	.word	.LC50
	.word	.LC51
	.size	test_protocols, .-test_protocols
	.section	.rodata
	.align	2
.LC52:
	.ascii	"Call: %s, returned: r_name: %s, r_number: %d\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	output_rpcent, %function
output_rpcent:
	@ 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]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L65
	ldr	r1, [fp, #-16]
	ldr	r0, .L70
	bl	printf
	b	.L69
.L65:
	ldr	r3, [fp, #-20]
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	ldr	r3, [r3, #8]
	ldr	r1, [fp, #-16]
	ldr	r0, .L70+4
	bl	printf
	ldr	r3, [fp, #-20]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-8]
	b	.L67
.L68:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L70+8
	bl	printf
	ldr	r3, [fp, #-8]
	add	r3, r3, #4
	str	r3, [fp, #-8]
.L67:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L68
.L69:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L71:
	.align	2
.L70:
	.word	.LC0
	.word	.LC52
	.word	.LC2
	.size	output_rpcent, .-output_rpcent
	.section	.rodata
	.align	2
.LC53:
	.ascii	"portmap\000"
	.align	2
.LC54:
	.ascii	"getrpcyname (\"portmap\")\000"
	.align	2
.LC55:
	.ascii	"getrpcbynumber (100000)\000"
	.align	2
.LC56:
	.ascii	"getrpcent ()\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	test_rpc, %function
test_rpc:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r0, .L74
	bl	getrpcbyname
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L74+4
	bl	output_rpcent
	ldr	r0, .L74+8
	bl	getrpcbynumber
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L74+12
	bl	output_rpcent
	mov	r0, #0
	bl	setrpcent
.L73:
	bl	getrpcent
	str	r0, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L74+16
	bl	output_rpcent
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L73
	bl	endrpcent
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L75:
	.align	2
.L74:
	.word	.LC53
	.word	.LC54
	.word	100000
	.word	.LC55
	.word	.LC56
	.size	test_rpc, .-test_rpc
	.section	.rodata
	.align	2
.LC57:
	.ascii	"db\000"
	.align	2
.LC58:
	.ascii	"hosts\000"
	.align	2
.LC59:
	.ascii	"networks\000"
	.align	2
.LC60:
	.ascii	"protocols\000"
	.align	2
.LC61:
	.ascii	"rpc\000"
	.align	2
.LC62:
	.ascii	"services\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	setdb, %function
setdb:
	@ 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]
	ldr	r1, [fp, #-8]
	ldr	r0, .L78
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L77
	ldr	r1, [fp, #-8]
	ldr	r0, .L78+4
	bl	__nss_configure_lookup
	ldr	r1, [fp, #-8]
	ldr	r0, .L78+8
	bl	__nss_configure_lookup
.L77:
	ldr	r1, [fp, #-8]
	ldr	r0, .L78+12
	bl	__nss_configure_lookup
	ldr	r1, [fp, #-8]
	ldr	r0, .L78+16
	bl	__nss_configure_lookup
	ldr	r1, [fp, #-8]
	ldr	r0, .L78+20
	bl	__nss_configure_lookup
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L79:
	.align	2
.L78:
	.word	.LC57
	.word	.LC58
	.word	.LC59
	.word	.LC60
	.word	.LC61
	.word	.LC62
	.size	setdb, .-setdb
	.section	.rodata
	.align	2
.LC63:
	.ascii	"\012 %d errors occurred!\012\000"
	.align	2
.LC64:
	.ascii	"No visible errors occurred!\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	bl	test_hosts
	bl	test_network
	bl	test_protocols
	bl	test_rpc
	bl	test_services
	ldr	r3, .L84
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L81
	ldr	r3, .L84
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L84+4
	bl	printf
	b	.L82
.L81:
	ldr	r0, .L84+8
	bl	puts
.L82:
	ldr	r3, .L84
	ldr	r3, [r3]
	cmp	r3, #0
	movne	r3, #1
	moveq	r3, #0
	and	r3, r3, #255
	mov	r0, r3
	pop	{fp, pc}
.L85:
	.align	2
.L84:
	.word	error_count
	.word	.LC63
	.word	.LC64
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
