	.file	"76206.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"Failed to get permission! (%s)\n"
	.align 8
.LC1:
	.string	"File system is read only! (%s)\n"
.LC2:
	.string	"Path is too long! (%s)\n"
	.align 8
.LC3:
	.string	"Failed to create directory! (%s)\n"
	.text
	.globl	NewDirectory
	.type	NewDirectory, @function
NewDirectory:
.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, 176
	mov	QWORD PTR -168[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdx, -160[rbp]
	mov	rax, QWORD PTR -168[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	stat@PLT
	cmp	eax, -1
	jne	.L2
	mov	rax, QWORD PTR -168[rbp]
	mov	esi, 511
	mov	rdi, rax
	call	mkdir@PLT
	test	eax, eax
	jne	.L3
	mov	eax, 1
	jmp	.L10
.L3:
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 36
	je	.L5
	cmp	eax, 36
	jg	.L6
	cmp	eax, 13
	je	.L7
	cmp	eax, 30
	je	.L8
	jmp	.L6
.L7:
	mov	rax, QWORD PTR -168[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
.L8:
	mov	rax, QWORD PTR -168[rbp]
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
.L5:
	mov	rax, QWORD PTR -168[rbp]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
.L6:
	mov	rax, QWORD PTR -168[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
	jmp	.L10
.L2:
	mov	eax, 1
.L10:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	NewDirectory, .-NewDirectory
	.globl	StripExtension
	.type	StripExtension, @function
StripExtension:
.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, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	cmp	QWORD PTR -32[rbp], 0
	je	.L13
	mov	rax, QWORD PTR -32[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L14
.L13:
	mov	rax, QWORD PTR -24[rbp]
	mov	BYTE PTR [rax], 0
	jmp	.L12
.L14:
	mov	rax, QWORD PTR -32[rbp]
	mov	esi, 46
	mov	rdi, rax
	call	strrchr@PLT
	mov	QWORD PTR -8[rbp], rax
	jmp	.L16
.L17:
	mov	rdx, QWORD PTR -32[rbp]
	lea	rax, 1[rdx]
	mov	QWORD PTR -32[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	lea	rcx, 1[rax]
	mov	QWORD PTR -24[rbp], rcx
	movzx	edx, BYTE PTR [rdx]
	mov	BYTE PTR [rax], dl
.L16:
	mov	rax, QWORD PTR -32[rbp]
	cmp	rax, QWORD PTR -8[rbp]
	jb	.L17
	mov	rax, QWORD PTR -24[rbp]
	mov	BYTE PTR [rax], 0
.L12:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	StripExtension, .-StripExtension
	.globl	LowerCasePath
	.type	LowerCasePath, @function
LowerCasePath:
.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, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	jmp	.L19
.L20:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	mov	edi, eax
	call	tolower@PLT
	mov	edx, eax
	mov	eax, DWORD PTR -4[rbp]
	movsx	rcx, eax
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rcx
	mov	BYTE PTR [rax], dl
	add	DWORD PTR -4[rbp], 1
.L19:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L20
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	LowerCasePath, .-LowerCasePath
	.globl	GetFileName
	.type	GetFileName, @function
GetFileName:
.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, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, 47
	mov	rdi, rax
	call	strrchr@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	je	.L22
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 1
	mov	QWORD PTR -24[rbp], rax
.L22:
	mov	rax, QWORD PTR -24[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	GetFileName, .-GetFileName
	.section	.rodata
.LC4:
	.string	""
	.text
	.globl	GetFileExtension
	.type	GetFileExtension, @function
GetFileExtension:
.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
	cmp	QWORD PTR -24[rbp], 0
	je	.L25
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L26
.L25:
	lea	rax, .LC4[rip]
	jmp	.L27
.L26:
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, 46
	mov	rdi, rax
	call	strrchr@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	je	.L28
	mov	rax, QWORD PTR -8[rbp]
	cmp	rax, QWORD PTR -24[rbp]
	jne	.L29
.L28:
	lea	rax, .LC4[rip]
	jmp	.L27
.L29:
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 1
.L27:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	GetFileExtension, .-GetFileExtension
	.globl	FileExists
	.type	FileExists, @function
FileExists:
.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, 176
	mov	QWORD PTR -168[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdx, -160[rbp]
	mov	rax, QWORD PTR -168[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	stat@PLT
	test	eax, eax
	sete	al
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L32
	call	__stack_chk_fail@PLT
.L32:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	FileExists, .-FileExists
	.section	.rodata
.LC5:
	.string	"Usage: mad <mad package path>"
.LC6:
	.string	"Failed to find %s!\n"
.LC7:
	.string	"rb"
.LC8:
	.string	"Failed to load %s!\n"
.LC9:
	.string	"./extract"
	.align 8
.LC10:
	.string	"Failed to create ./extract directory!"
.LC11:
	.string	"%s"
.LC12:
	.string	"Extracting %s...\n"
	.align 8
.LC13:
	.string	"Unexpected index size for index %d, in %s!\n"
	.align 8
.LC14:
	.string	"Invalid extension for %s, skipping!\n"
.LC15:
	.string	"./extract/%s_%s"
	.align 8
.LC16:
	.string	"Failed to create directory at %s!\n"
.LC17:
	.string	"./extract/%s_%s/%s"
.LC18:
	.string	"Writing %s...\n"
.LC19:
	.string	"wb"
.LC20:
	.string	"Failed to write %s!\n"
.LC21:
	.string	"DONE!"
	.text
	.globl	main
	.type	main, @function
main:
.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, 896
	mov	DWORD PTR -884[rbp], edi
	mov	QWORD PTR -896[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -884[rbp], 0
	jg	.L34
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	eax, 0
	jmp	.L50
.L34:
	mov	rax, QWORD PTR -896[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -864[rbp], rax
	mov	rax, QWORD PTR -864[rbp]
	mov	rdi, rax
	call	FileExists
	xor	eax, 1
	test	al, al
	je	.L36
	mov	rax, QWORD PTR -864[rbp]
	mov	rsi, rax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 1
	jmp	.L50
.L36:
	mov	rax, QWORD PTR -864[rbp]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -856[rbp], rax
	cmp	QWORD PTR -856[rbp], 0
	jne	.L37
	mov	rax, QWORD PTR -864[rbp]
	mov	rsi, rax
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 1
	jmp	.L50
.L37:
	lea	rdi, .LC9[rip]
	call	NewDirectory
	xor	eax, 1
	test	al, al
	je	.L38
	lea	rdi, .LC10[rip]
	call	puts@PLT
	mov	eax, 1
	jmp	.L50
.L38:
	mov	QWORD PTR -784[rbp], 0
	mov	QWORD PTR -776[rbp], 0
	mov	QWORD PTR -768[rbp], 0
	mov	QWORD PTR -760[rbp], 0
	mov	QWORD PTR -752[rbp], 0
	mov	QWORD PTR -744[rbp], 0
	mov	QWORD PTR -736[rbp], 0
	mov	QWORD PTR -728[rbp], 0
	mov	QWORD PTR -720[rbp], 0
	mov	QWORD PTR -712[rbp], 0
	mov	QWORD PTR -704[rbp], 0
	mov	QWORD PTR -696[rbp], 0
	mov	QWORD PTR -688[rbp], 0
	mov	QWORD PTR -680[rbp], 0
	mov	QWORD PTR -672[rbp], 0
	mov	QWORD PTR -664[rbp], 0
	mov	QWORD PTR -656[rbp], 0
	mov	QWORD PTR -648[rbp], 0
	mov	QWORD PTR -640[rbp], 0
	mov	QWORD PTR -632[rbp], 0
	mov	QWORD PTR -624[rbp], 0
	mov	QWORD PTR -616[rbp], 0
	mov	QWORD PTR -608[rbp], 0
	mov	QWORD PTR -600[rbp], 0
	mov	QWORD PTR -592[rbp], 0
	mov	QWORD PTR -584[rbp], 0
	mov	QWORD PTR -576[rbp], 0
	mov	QWORD PTR -568[rbp], 0
	mov	QWORD PTR -560[rbp], 0
	mov	QWORD PTR -552[rbp], 0
	mov	QWORD PTR -544[rbp], 0
	mov	QWORD PTR -536[rbp], 0
	mov	rax, QWORD PTR -864[rbp]
	mov	rdi, rax
	call	GetFileName
	mov	rdx, rax
	lea	rax, -784[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	StripExtension
	lea	rax, -784[rbp]
	mov	rdi, rax
	call	LowerCasePath
	mov	QWORD PTR -528[rbp], 0
	mov	QWORD PTR -520[rbp], 0
	mov	QWORD PTR -512[rbp], 0
	mov	QWORD PTR -504[rbp], 0
	mov	QWORD PTR -496[rbp], 0
	mov	QWORD PTR -488[rbp], 0
	mov	QWORD PTR -480[rbp], 0
	mov	QWORD PTR -472[rbp], 0
	mov	QWORD PTR -464[rbp], 0
	mov	QWORD PTR -456[rbp], 0
	mov	QWORD PTR -448[rbp], 0
	mov	QWORD PTR -440[rbp], 0
	mov	QWORD PTR -432[rbp], 0
	mov	QWORD PTR -424[rbp], 0
	mov	QWORD PTR -416[rbp], 0
	mov	QWORD PTR -408[rbp], 0
	mov	QWORD PTR -400[rbp], 0
	mov	QWORD PTR -392[rbp], 0
	mov	QWORD PTR -384[rbp], 0
	mov	QWORD PTR -376[rbp], 0
	mov	QWORD PTR -368[rbp], 0
	mov	QWORD PTR -360[rbp], 0
	mov	QWORD PTR -352[rbp], 0
	mov	QWORD PTR -344[rbp], 0
	mov	QWORD PTR -336[rbp], 0
	mov	QWORD PTR -328[rbp], 0
	mov	QWORD PTR -320[rbp], 0
	mov	QWORD PTR -312[rbp], 0
	mov	QWORD PTR -304[rbp], 0
	mov	QWORD PTR -296[rbp], 0
	mov	QWORD PTR -288[rbp], 0
	mov	QWORD PTR -280[rbp], 0
	mov	rax, QWORD PTR -864[rbp]
	mov	rdi, rax
	call	GetFileExtension
	mov	rdx, rax
	lea	rax, -528[rbp]
	mov	rcx, rdx
	lea	rdx, .LC11[rip]
	mov	esi, 256
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	lea	rax, -528[rbp]
	mov	rdi, rax
	call	LowerCasePath
	mov	rax, QWORD PTR -864[rbp]
	mov	rdi, rax
	call	GetFileName
	mov	rsi, rax
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -872[rbp], -1
	mov	DWORD PTR -868[rbp], 0
.L49:
	add	DWORD PTR -868[rbp], 1
	mov	rdx, QWORD PTR -856[rbp]
	lea	rax, -816[rbp]
	mov	rcx, rdx
	mov	edx, 1
	mov	esi, 24
	mov	rdi, rax
	call	fread@PLT
	cmp	rax, 1
	je	.L39
	mov	rax, QWORD PTR -864[rbp]
	mov	rdi, rax
	call	GetFileName
	mov	rdx, rax
	mov	eax, DWORD PTR -868[rbp]
	mov	esi, eax
	lea	rdi, .LC13[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 1
	jmp	.L50
.L39:
	mov	rax, QWORD PTR -856[rbp]
	mov	rdi, rax
	call	ftell@PLT
	mov	QWORD PTR -848[rbp], rax
	mov	eax, DWORD PTR -800[rbp]
	cmp	DWORD PTR -872[rbp], eax
	jbe	.L41
	mov	eax, DWORD PTR -800[rbp]
	mov	DWORD PTR -872[rbp], eax
.L41:
	lea	rax, -816[rbp]
	mov	rdi, rax
	call	GetFileExtension
	mov	QWORD PTR -840[rbp], rax
	cmp	QWORD PTR -840[rbp], 0
	je	.L42
	mov	rax, QWORD PTR -840[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L43
.L42:
	lea	rax, -816[rbp]
	mov	rsi, rax
	lea	rdi, .LC14[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L44
.L43:
	lea	rcx, -528[rbp]
	lea	rdx, -784[rbp]
	lea	rax, -272[rbp]
	mov	r8, rcx
	mov	rcx, rdx
	lea	rdx, .LC15[rip]
	mov	esi, 256
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	lea	rax, -272[rbp]
	mov	rdi, rax
	call	NewDirectory
	xor	eax, 1
	test	al, al
	je	.L45
	lea	rax, -272[rbp]
	mov	rsi, rax
	lea	rdi, .LC16[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 1
	jmp	.L50
.L45:
	lea	rsi, -816[rbp]
	lea	rcx, -528[rbp]
	lea	rdx, -784[rbp]
	lea	rax, -272[rbp]
	mov	r9, rsi
	mov	r8, rcx
	mov	rcx, rdx
	lea	rdx, .LC17[rip]
	mov	esi, 256
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	lea	rax, -272[rbp]
	mov	rdi, rax
	call	LowerCasePath
	mov	eax, DWORD PTR -800[rbp]
	mov	ecx, eax
	mov	rax, QWORD PTR -856[rbp]
	mov	edx, 0
	mov	rsi, rcx
	mov	rdi, rax
	call	fseek@PLT
	mov	eax, DWORD PTR -796[rbp]
	mov	eax, eax
	mov	esi, 1
	mov	rdi, rax
	call	calloc@PLT
	mov	QWORD PTR -832[rbp], rax
	mov	eax, DWORD PTR -796[rbp]
	mov	esi, eax
	mov	rdx, QWORD PTR -856[rbp]
	mov	rax, QWORD PTR -832[rbp]
	mov	rcx, rdx
	mov	rdx, rsi
	mov	esi, 1
	mov	rdi, rax
	call	fread@PLT
	mov	edx, DWORD PTR -796[rbp]
	mov	edx, edx
	cmp	rax, rdx
	jne	.L46
	lea	rax, -272[rbp]
	mov	rsi, rax
	lea	rdi, .LC18[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -272[rbp]
	lea	rsi, .LC19[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -824[rbp], rax
	cmp	QWORD PTR -824[rbp], 0
	je	.L47
	mov	eax, DWORD PTR -796[rbp]
	mov	esi, eax
	mov	rdx, QWORD PTR -824[rbp]
	mov	rax, QWORD PTR -832[rbp]
	mov	rcx, rdx
	mov	rdx, rsi
	mov	esi, 1
	mov	rdi, rax
	call	fwrite@PLT
	mov	edx, DWORD PTR -796[rbp]
	mov	edx, edx
	cmp	rax, rdx
	je	.L48
.L47:
	lea	rax, -272[rbp]
	mov	rsi, rax
	lea	rdi, .LC20[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 1
	jmp	.L50
.L48:
	mov	rax, QWORD PTR -824[rbp]
	mov	rdi, rax
	call	fclose@PLT
.L46:
	mov	rax, QWORD PTR -832[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rcx, QWORD PTR -848[rbp]
	mov	rax, QWORD PTR -856[rbp]
	mov	edx, 0
	mov	rsi, rcx
	mov	rdi, rax
	call	fseek@PLT
.L44:
	mov	eax, DWORD PTR -872[rbp]
	cmp	QWORD PTR -848[rbp], rax
	jl	.L49
	mov	rax, QWORD PTR -856[rbp]
	mov	rdi, rax
	call	fclose@PLT
	lea	rdi, .LC21[rip]
	call	puts@PLT
	mov	eax, 0
.L50:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L51
	call	__stack_chk_fail@PLT
.L51:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.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	"76206.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Failed to get permission! (%s)\012\000"
	.align	2
.LC1:
	.ascii	"File system is read only! (%s)\012\000"
	.align	2
.LC2:
	.ascii	"Path is too long! (%s)\012\000"
	.align	2
.LC3:
	.ascii	"Failed to create directory! (%s)\012\000"
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	NewDirectory
	.syntax unified
	.arm
	.fpu softvfp
	.type	NewDirectory, %function
NewDirectory:
	@ args = 0, pretend = 0, frame = 104
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #104
	str	r0, [fp, #-104]
	ldr	r3, .L12
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #100
	mov	r1, r3
	ldr	r0, [fp, #-104]
	bl	stat
	mov	r3, r0
	cmn	r3, #1
	bne	.L2
	ldr	r1, .L12+4
	ldr	r0, [fp, #-104]
	bl	mkdir
	mov	r3, r0
	cmp	r3, #0
	bne	.L3
	mov	r3, #1
	b	.L10
.L3:
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #36
	beq	.L5
	cmp	r3, #36
	bgt	.L6
	cmp	r3, #13
	beq	.L7
	cmp	r3, #30
	beq	.L8
	b	.L6
.L7:
	ldr	r1, [fp, #-104]
	ldr	r0, .L12+8
	bl	printf
.L8:
	ldr	r1, [fp, #-104]
	ldr	r0, .L12+12
	bl	printf
.L5:
	ldr	r1, [fp, #-104]
	ldr	r0, .L12+16
	bl	printf
.L6:
	ldr	r1, [fp, #-104]
	ldr	r0, .L12+20
	bl	printf
	mov	r3, #0
	b	.L10
.L2:
	mov	r3, #1
.L10:
	ldr	r2, .L12
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L11
	bl	__stack_chk_fail
.L11:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L13:
	.align	2
.L12:
	.word	.LC4
	.word	511
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.size	NewDirectory, .-NewDirectory
	.align	2
	.global	StripExtension
	.syntax unified
	.arm
	.fpu softvfp
	.type	StripExtension, %function
StripExtension:
	@ 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
	beq	.L15
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L16
.L15:
	ldr	r3, [fp, #-16]
	mov	r2, #0
	strb	r2, [r3]
	b	.L14
.L16:
	mov	r1, #46
	ldr	r0, [fp, #-20]
	bl	strrchr
	str	r0, [fp, #-8]
	b	.L18
.L19:
	ldr	r2, [fp, #-20]
	add	r3, r2, #1
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-16]
	add	r1, r3, #1
	str	r1, [fp, #-16]
	ldrb	r2, [r2]	@ zero_extendqisi2
	strb	r2, [r3]
.L18:
	ldr	r2, [fp, #-20]
	ldr	r3, [fp, #-8]
	cmp	r2, r3
	bcc	.L19
	ldr	r3, [fp, #-16]
	mov	r2, #0
	strb	r2, [r3]
.L14:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	StripExtension, .-StripExtension
	.align	2
	.global	LowerCasePath
	.syntax unified
	.arm
	.fpu softvfp
	.type	LowerCasePath, %function
LowerCasePath:
	@ 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]
	b	.L21
.L22:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r0, r3
	bl	tolower
	mov	r1, r0
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	and	r2, r1, #255
	strb	r2, [r3]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L21:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L22
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	LowerCasePath, .-LowerCasePath
	.align	2
	.global	GetFileName
	.syntax unified
	.arm
	.fpu softvfp
	.type	GetFileName, %function
GetFileName:
	@ 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	r1, #47
	ldr	r0, [fp, #-16]
	bl	strrchr
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L24
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L24:
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	GetFileName, .-GetFileName
	.section	.rodata
	.align	2
.LC5:
	.ascii	"\000"
	.text
	.align	2
	.global	GetFileExtension
	.syntax unified
	.arm
	.fpu softvfp
	.type	GetFileExtension, %function
GetFileExtension:
	@ 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]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	beq	.L27
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L28
.L27:
	ldr	r3, .L32
	b	.L29
.L28:
	mov	r1, #46
	ldr	r0, [fp, #-16]
	bl	strrchr
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L30
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	cmp	r2, r3
	bne	.L31
.L30:
	ldr	r3, .L32
	b	.L29
.L31:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
.L29:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L33:
	.align	2
.L32:
	.word	.LC5
	.size	GetFileExtension, .-GetFileExtension
	.section	.rodata
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	FileExists
	.syntax unified
	.arm
	.fpu softvfp
	.type	FileExists, %function
FileExists:
	@ args = 0, pretend = 0, frame = 104
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #104
	str	r0, [fp, #-104]
	ldr	r3, .L37
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #100
	mov	r1, r3
	ldr	r0, [fp, #-104]
	bl	stat
	mov	r3, r0
	cmp	r3, #0
	moveq	r3, #1
	movne	r3, #0
	and	r3, r3, #255
	ldr	r2, .L37
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L36
	bl	__stack_chk_fail
.L36:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L38:
	.align	2
.L37:
	.word	.LC6
	.size	FileExists, .-FileExists
	.section	.rodata
	.align	2
.LC7:
	.ascii	"Usage: mad <mad package path>\000"
	.align	2
.LC8:
	.ascii	"Failed to find %s!\012\000"
	.align	2
.LC9:
	.ascii	"rb\000"
	.align	2
.LC10:
	.ascii	"Failed to load %s!\012\000"
	.align	2
.LC11:
	.ascii	"./extract\000"
	.align	2
.LC12:
	.ascii	"Failed to create ./extract directory!\000"
	.align	2
.LC13:
	.ascii	"%s\000"
	.align	2
.LC14:
	.ascii	"Extracting %s...\012\000"
	.align	2
.LC15:
	.ascii	"Unexpected index size for index %d, in %s!\012\000"
	.align	2
.LC16:
	.ascii	"Invalid extension for %s, skipping!\012\000"
	.align	2
.LC17:
	.ascii	"./extract/%s_%s\000"
	.align	2
.LC18:
	.ascii	"Failed to create directory at %s!\012\000"
	.align	2
.LC19:
	.ascii	"./extract/%s_%s/%s\000"
	.align	2
.LC20:
	.ascii	"Writing %s...\012\000"
	.align	2
.LC21:
	.ascii	"wb\000"
	.align	2
.LC22:
	.ascii	"Failed to write %s!\012\000"
	.align	2
.LC23:
	.ascii	"DONE!\000"
	.align	2
.LC24:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 840
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #848
	str	r0, [fp, #-840]
	str	r1, [fp, #-844]
	ldr	r3, .L58
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-840]
	cmp	r3, #0
	bgt	.L40
	ldr	r0, .L58+4
	bl	puts
	mov	r3, #0
	b	.L56
.L40:
	ldr	r3, [fp, #-844]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-824]
	ldr	r0, [fp, #-824]
	bl	FileExists
	mov	r3, r0
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L42
	ldr	r1, [fp, #-824]
	ldr	r0, .L58+8
	bl	printf
	mov	r3, #1
	b	.L56
.L42:
	ldr	r1, .L58+12
	ldr	r0, [fp, #-824]
	bl	fopen
	str	r0, [fp, #-820]
	ldr	r3, [fp, #-820]
	cmp	r3, #0
	bne	.L43
	ldr	r1, [fp, #-824]
	ldr	r0, .L58+16
	bl	printf
	mov	r3, #1
	b	.L56
.L43:
	ldr	r0, .L58+20
	bl	NewDirectory
	mov	r3, r0
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L44
	ldr	r0, .L58+24
	bl	puts
	mov	r3, #1
	b	.L56
.L44:
	mov	r3, #0
	str	r3, [fp, #-776]
	sub	r3, fp, #772
	mov	r2, #252
	mov	r1, #0
	mov	r0, r3
	bl	memset
	ldr	r0, [fp, #-824]
	bl	GetFileName
	mov	r2, r0
	sub	r3, fp, #776
	mov	r1, r2
	mov	r0, r3
	bl	StripExtension
	sub	r3, fp, #776
	mov	r0, r3
	bl	LowerCasePath
	mov	r3, #0
	str	r3, [fp, #-520]
	sub	r3, fp, #516
	mov	r2, #252
	mov	r1, #0
	mov	r0, r3
	bl	memset
	ldr	r0, [fp, #-824]
	bl	GetFileExtension
	mov	r3, r0
	sub	r0, fp, #520
	ldr	r2, .L58+28
	mov	r1, #256
	bl	snprintf
	sub	r3, fp, #520
	mov	r0, r3
	bl	LowerCasePath
	ldr	r0, [fp, #-824]
	bl	GetFileName
	mov	r3, r0
	mov	r1, r3
	ldr	r0, .L58+32
	bl	printf
	mvn	r3, #0
	str	r3, [fp, #-832]
	mov	r3, #0
	str	r3, [fp, #-828]
.L55:
	ldr	r3, [fp, #-828]
	add	r3, r3, #1
	str	r3, [fp, #-828]
	sub	r0, fp, #800
	ldr	r3, [fp, #-820]
	mov	r2, #1
	mov	r1, #24
	bl	fread
	mov	r3, r0
	cmp	r3, #1
	beq	.L45
	ldr	r0, [fp, #-824]
	bl	GetFileName
	mov	r3, r0
	mov	r2, r3
	ldr	r1, [fp, #-828]
	ldr	r0, .L58+36
	bl	printf
	mov	r3, #1
	b	.L56
.L45:
	ldr	r0, [fp, #-820]
	bl	ftell
	str	r0, [fp, #-816]
	ldr	r3, [fp, #-784]
	ldr	r2, [fp, #-832]
	cmp	r2, r3
	bls	.L47
	ldr	r3, [fp, #-784]
	str	r3, [fp, #-832]
.L47:
	sub	r3, fp, #800
	mov	r0, r3
	bl	GetFileExtension
	str	r0, [fp, #-812]
	ldr	r3, [fp, #-812]
	cmp	r3, #0
	beq	.L48
	ldr	r3, [fp, #-812]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L49
.L48:
	sub	r3, fp, #800
	mov	r1, r3
	ldr	r0, .L58+40
	bl	printf
	b	.L50
.L49:
	sub	r2, fp, #776
	sub	r0, fp, #264
	sub	r3, fp, #520
	str	r3, [sp]
	mov	r3, r2
	ldr	r2, .L58+44
	mov	r1, #256
	bl	snprintf
	sub	r3, fp, #264
	mov	r0, r3
	bl	NewDirectory
	mov	r3, r0
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L51
	sub	r3, fp, #264
	mov	r1, r3
	ldr	r0, .L58+48
	bl	printf
	mov	r3, #1
	b	.L56
.L51:
	sub	r2, fp, #776
	sub	r0, fp, #264
	sub	r3, fp, #800
	str	r3, [sp, #4]
	sub	r3, fp, #520
	str	r3, [sp]
	mov	r3, r2
	ldr	r2, .L58+52
	mov	r1, #256
	bl	snprintf
	sub	r3, fp, #264
	mov	r0, r3
	bl	LowerCasePath
	ldr	r3, [fp, #-784]
	mov	r2, #0
	mov	r1, r3
	ldr	r0, [fp, #-820]
	bl	fseek
	ldr	r3, [fp, #-780]
	mov	r1, #1
	mov	r0, r3
	bl	calloc
	mov	r3, r0
	str	r3, [fp, #-808]
	ldr	r2, [fp, #-780]
	ldr	r3, [fp, #-820]
	mov	r1, #1
	ldr	r0, [fp, #-808]
	bl	fread
	mov	r2, r0
	ldr	r3, [fp, #-780]
	cmp	r2, r3
	bne	.L52
	sub	r3, fp, #264
	mov	r1, r3
	ldr	r0, .L58+56
	bl	printf
	sub	r3, fp, #264
	ldr	r1, .L58+60
	mov	r0, r3
	bl	fopen
	str	r0, [fp, #-804]
	ldr	r3, [fp, #-804]
	cmp	r3, #0
	beq	.L53
	ldr	r2, [fp, #-780]
	ldr	r3, [fp, #-804]
	mov	r1, #1
	ldr	r0, [fp, #-808]
	bl	fwrite
	mov	r2, r0
	ldr	r3, [fp, #-780]
	cmp	r2, r3
	beq	.L54
.L53:
	sub	r3, fp, #264
	mov	r1, r3
	ldr	r0, .L58+64
	bl	printf
	mov	r3, #1
	b	.L56
.L54:
	ldr	r0, [fp, #-804]
	bl	fclose
.L52:
	ldr	r0, [fp, #-808]
	bl	free
	mov	r2, #0
	ldr	r1, [fp, #-816]
	ldr	r0, [fp, #-820]
	bl	fseek
.L50:
	ldr	r3, [fp, #-816]
	ldr	r2, [fp, #-832]
	cmp	r2, r3
	bhi	.L55
	ldr	r0, [fp, #-820]
	bl	fclose
	ldr	r0, .L58+68
	bl	puts
	mov	r3, #0
.L56:
	ldr	r2, .L58
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L57
	bl	__stack_chk_fail
.L57:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L59:
	.align	2
.L58:
	.word	.LC24
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.word	.LC16
	.word	.LC17
	.word	.LC18
	.word	.LC19
	.word	.LC20
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
