4080ed:	8b 45 10             	mov    0x10(%ebp),%eax
4080f0:	89 38                	mov    %edi,(%eax)
4080f2:	8b c6                	mov    %esi,%eax
4080f4:	5f                   	pop    %edi
4080f5:	5e                   	pop    %esi
4080f6:	5b                   	pop    %ebx
4080f7:	c9                   	leave
4080f8:	c2 0c 00             	ret    $0xc
4080fb:	8b ff                	mov    %edi,%edi
4080fd:	55                   	push   %ebp
4080fe:	8b ec                	mov    %esp,%ebp
408100:	83 ec 0c             	sub    $0xc,%esp
408103:	53                   	push   %ebx
408104:	8b 5d 10             	mov    0x10(%ebp),%ebx
408107:	56                   	push   %esi
408108:	57                   	push   %edi
408109:	89 4d f4             	mov    %ecx,-0xc(%ebp)
40810c:	8b cb                	mov    %ebx,%ecx
40810e:	6a 10                	push   $0x10
408110:	89 55 f8             	mov    %edx,-0x8(%ebp)
408113:	e8 1b 01 00 00       	call   0x408233
408118:	8b 43 04             	mov    0x4(%ebx),%eax
40811b:	8d 4d fc             	lea    -0x4(%ebp),%ecx
40811e:	2b 03                	sub    (%ebx),%eax
408120:	33 ff                	xor    %edi,%edi
408122:	51                   	push   %ecx
408123:	ff 33                	push   (%ebx)
408125:	89 45 fc             	mov    %eax,-0x4(%ebp)
408128:	8b f7                	mov    %edi,%esi
40812a:	50                   	push   %eax
40812b:	57                   	push   %edi
40812c:	ff 75 08             	push   0x8(%ebp)
40812f:	ff 75 f8             	push   -0x8(%ebp)
408132:	ff 75 f4             	push   -0xc(%ebp)
408135:	ff 15 38 20 41 00    	call   *0x412038
40813b:	85 c0                	test   %eax,%eax
40813d:	75 48                	jne    0x408187
40813f:	ff 15 70 20 41 00    	call   *0x412070
408145:	8b f0                	mov    %eax,%esi
408147:	83 fe 7a             	cmp    $0x7a,%esi
40814a:	75 37                	jne    0x408183
40814c:	ff 75 fc             	push   -0x4(%ebp)
40814f:	8b cb                	mov    %ebx,%ecx
408151:	e8 dd 00 00 00       	call   0x408233
408156:	8b 43 04             	mov    0x4(%ebx),%eax
408159:	8d 4d fc             	lea    -0x4(%ebp),%ecx
40815c:	2b 03                	sub    (%ebx),%eax
40815e:	8b f7                	mov    %edi,%esi
408160:	51                   	push   %ecx
408161:	ff 33                	push   (%ebx)
408163:	89 45 fc             	mov    %eax,-0x4(%ebp)
408166:	50                   	push   %eax
408167:	57                   	push   %edi
408168:	ff 75 08             	push   0x8(%ebp)
40816b:	ff 75 f8             	push   -0x8(%ebp)
40816e:	ff 75 f4             	push   -0xc(%ebp)
408171:	ff 15 38 20 41 00    	call   *0x412038
408177:	85 c0                	test   %eax,%eax
408179:	75 0c                	jne    0x408187
40817b:	ff 15 70 20 41 00    	call   *0x412070
408181:	8b f0                	mov    %eax,%esi
408183:	85 f6                	test   %esi,%esi
408185:	75 02                	jne    0x408189
408187:	8b 3b                	mov    (%ebx),%edi
408189:	8b 45 14             	mov    0x14(%ebp),%eax
40818c:	89 38                	mov    %edi,(%eax)
40818e:	8b c6                	mov    %esi,%eax
408190:	5f                   	pop    %edi
408191:	5e                   	pop    %esi
408192:	5b                   	pop    %ebx
408193:	c9                   	leave
408194:	c2 10 00             	ret    $0x10
408197:	8b ff                	mov    %edi,%edi
408199:	55                   	push   %ebp
40819a:	8b ec                	mov    %esp,%ebp
40819c:	83 ec 0c             	sub    $0xc,%esp
40819f:	53                   	push   %ebx
4081a0:	8b 5d 10             	mov    0x10(%ebp),%ebx
4081a3:	56                   	push   %esi
4081a4:	57                   	push   %edi
4081a5:	89 4d f4             	mov    %ecx,-0xc(%ebp)
4081a8:	8b cb                	mov    %ebx,%ecx
4081aa:	6a 10                	push   $0x10
4081ac:	89 55 f8             	mov    %edx,-0x8(%ebp)
4081af:	e8 7f 00 00 00       	call   0x408233
4081b4:	8b 43 04             	mov    0x4(%ebx),%eax
4081b7:	8d 4d fc             	lea    -0x4(%ebp),%ecx
4081ba:	2b 03                	sub    (%ebx),%eax
4081bc:	33 ff                	xor    %edi,%edi
4081be:	51                   	push   %ecx
4081bf:	ff 33                	push   (%ebx)
4081c1:	89 45 fc             	mov    %eax,-0x4(%ebp)
4081c4:	8b f7                	mov    %edi,%esi
4081c6:	50                   	push   %eax
4081c7:	57                   	push   %edi
4081c8:	ff 75 08             	push   0x8(%ebp)
4081cb:	ff 75 f8             	push   -0x8(%ebp)
4081ce:	ff 75 f4             	push   -0xc(%ebp)
4081d1:	ff 15 3c 20 41 00    	call   *0x41203c
4081d7:	85 c0                	test   %eax,%eax
4081d9:	75 48                	jne    0x408223
4081db:	ff 15 70 20 41 00    	call   *0x412070
4081e1:	8b f0                	mov    %eax,%esi
4081e3:	83 fe 7a             	cmp    $0x7a,%esi
4081e6:	75 37                	jne    0x40821f
4081e8:	ff 75 fc             	push   -0x4(%ebp)
4081eb:	8b cb                	mov    %ebx,%ecx
4081ed:	e8 41 00 00 00       	call   0x408233
4081f2:	8b 43 04             	mov    0x4(%ebx),%eax
4081f5:	8d 4d fc             	lea    -0x4(%ebp),%ecx
4081f8:	2b 03                	sub    (%ebx),%eax
4081fa:	8b f7                	mov    %edi,%esi
4081fc:	51                   	push   %ecx
4081fd:	ff 33                	push   (%ebx)
4081ff:	89 45 fc             	mov    %eax,-0x4(%ebp)
408202:	50                   	push   %eax
408203:	57                   	push   %edi
408204:	ff 75 08             	push   0x8(%ebp)
408207:	ff 75 f8             	push   -0x8(%ebp)
40820a:	ff 75 f4             	push   -0xc(%ebp)
40820d:	ff 15 3c 20 41 00    	call   *0x41203c
408213:	85 c0                	test   %eax,%eax
408215:	75 0c                	jne    0x408223
408217:	ff 15 70 20 41 00    	call   *0x412070
40821d:	8b f0                	mov    %eax,%esi
40821f:	85 f6                	test   %esi,%esi
408221:	75 02                	jne    0x408225
408223:	8b 3b                	mov    (%ebx),%edi
408225:	8b 45 14             	mov    0x14(%ebp),%eax
408228:	89 38                	mov    %edi,(%eax)
40822a:	8b c6                	mov    %esi,%eax
40822c:	5f                   	pop    %edi
40822d:	5e                   	pop    %esi
40822e:	5b                   	pop    %ebx
40822f:	c9                   	leave
408230:	c2 10 00             	ret    $0x10
408233:	8b ff                	mov    %edi,%edi
408235:	55                   	push   %ebp
408236:	8b ec                	mov    %esp,%ebp
408238:	56                   	push   %esi
408239:	8b f1                	mov    %ecx,%esi
40823b:	57                   	push   %edi
40823c:	8b 7d 08             	mov    0x8(%ebp),%edi
40823f:	8b 46 04             	mov    0x4(%esi),%eax
408242:	8b 0e                	mov    (%esi),%ecx
408244:	2b c1                	sub    %ecx,%eax
408246:	3b f8                	cmp    %eax,%edi
408248:	73 13                	jae    0x40825d
40824a:	8d 04 39             	lea    (%ecx,%edi,1),%eax
40824d:	3b c1                	cmp    %ecx,%eax
40824f:	75 05                	jne    0x408256
408251:	89 4e 04             	mov    %ecx,0x4(%esi)
408254:	eb 32                	jmp    0x408288
408256:	3b 46 04             	cmp    0x4(%esi),%eax
408259:	74 2d                	je     0x408288
40825b:	eb 28                	jmp    0x408285
40825d:	76 29                	jbe    0x408288
40825f:	2b 4e 04             	sub    0x4(%esi),%ecx
408262:	03 cf                	add    %edi,%ecx
408264:	51                   	push   %ecx
408265:	8b ce                	mov    %esi,%ecx
408267:	e8 22 00 00 00       	call   0x40828e
40826c:	8b 06                	mov    (%esi),%eax
40826e:	2b 46 04             	sub    0x4(%esi),%eax
408271:	03 c7                	add    %edi,%eax
408273:	50                   	push   %eax
408274:	6a 00                	push   $0x0
408276:	ff 76 04             	push   0x4(%esi)
408279:	e8 d1 69 00 00       	call   0x40ec4f
40827e:	8b 06                	mov    (%esi),%eax
408280:	83 c4 0c             	add    $0xc,%esp
408283:	03 c7                	add    %edi,%eax
408285:	89 46 04             	mov    %eax,0x4(%esi)
408288:	5f                   	pop    %edi
408289:	5e                   	pop    %esi
40828a:	5d                   	pop    %ebp
40828b:	c2 04 00             	ret    $0x4
40828e:	8b ff                	mov    %edi,%edi
408290:	55                   	push   %ebp
408291:	8b ec                	mov    %esp,%ebp
408293:	56                   	push   %esi
408294:	8b f1                	mov    %ecx,%esi
408296:	57                   	push   %edi
408297:	8b 7e 08             	mov    0x8(%esi),%edi
40829a:	8b c7                	mov    %edi,%eax
40829c:	8b 56 04             	mov    0x4(%esi),%edx
40829f:	2b c2                	sub    %edx,%eax
4082a1:	3b 45 08             	cmp    0x8(%ebp),%eax
4082a4:	73 31                	jae    0x4082d7
4082a6:	8b 06                	mov    (%esi),%eax
4082a8:	2b c2                	sub    %edx,%eax
4082aa:	48                   	dec    %eax
4082ab:	3b 45 08             	cmp    0x8(%ebp),%eax
4082ae:	72 2d                	jb     0x4082dd
4082b0:	2b 3e                	sub    (%esi),%edi
4082b2:	2b 16                	sub    (%esi),%edx
4082b4:	8b cf                	mov    %edi,%ecx
4082b6:	03 55 08             	add    0x8(%ebp),%edx
4082b9:	d1 e9                	shr    $1,%ecx
4082bb:	8b c1                	mov    %ecx,%eax
4082bd:	03 cf                	add    %edi,%ecx
4082bf:	f7 d0                	not    %eax
4082c1:	3b c7                	cmp    %edi,%eax
4082c3:	1b c0                	sbb    %eax,%eax
4082c5:	f7 d0                	not    %eax
4082c7:	23 c1                	and    %ecx,%eax
4082c9:	3b c2                	cmp    %edx,%eax
4082cb:	73 02                	jae    0x4082cf
4082cd:	8b c2                	mov    %edx,%eax
4082cf:	50                   	push   %eax
4082d0:	8b ce                	mov    %esi,%ecx
4082d2:	e8 0c 00 00 00       	call   0x4082e3
4082d7:	5f                   	pop    %edi
4082d8:	5e                   	pop    %esi
4082d9:	5d                   	pop    %ebp
4082da:	c2 04 00             	ret    $0x4
4082dd:	e8 68 ea ff ff       	call   0x406d4a
4082e2:	cc                   	int3
4082e3:	8b ff                	mov    %edi,%edi
4082e5:	55                   	push   %ebp
4082e6:	8b ec                	mov    %esp,%ebp
4082e8:	51                   	push   %ecx
4082e9:	53                   	push   %ebx
4082ea:	8b 5d 08             	mov    0x8(%ebp),%ebx
4082ed:	56                   	push   %esi
4082ee:	33 f6                	xor    %esi,%esi
4082f0:	57                   	push   %edi
4082f1:	8b f9                	mov    %ecx,%edi
4082f3:	85 db                	test   %ebx,%ebx
4082f5:	74 0d                	je     0x408304
4082f7:	53                   	push   %ebx
4082f8:	e8 cb 5b 00 00       	call   0x40dec8
4082fd:	8b f0                	mov    %eax,%esi
4082ff:	59                   	pop    %ecx
408300:	85 f6                	test   %esi,%esi
408302:	74 3e                	je     0x408342
408304:	8b 47 04             	mov    0x4(%edi),%eax
408307:	2b 07                	sub    (%edi),%eax
408309:	50                   	push   %eax
40830a:	ff 37                	push   (%edi)
40830c:	56                   	push   %esi
40830d:	e8 1a 64 00 00       	call   0x40e72c
408312:	8b 47 04             	mov    0x4(%edi),%eax
408315:	83 c4 0c             	add    $0xc,%esp
408318:	2b 07                	sub    (%edi),%eax
40831a:	83 3f 00             	cmpl   $0x0,(%edi)
40831d:	89 45 fc             	mov    %eax,-0x4(%ebp)
408320:	74 09                	je     0x40832b
408322:	ff 37                	push   (%edi)
408324:	ff 15 e4 21 41 00    	call   *0x4121e4
40832a:	59                   	pop    %ecx
40832b:	8d 04 1e             	lea    (%esi,%ebx,1),%eax
40832e:	89 37                	mov    %esi,(%edi)
408330:	89 47 08             	mov    %eax,0x8(%edi)
408333:	8b 45 fc             	mov    -0x4(%ebp),%eax
408336:	03 c6                	add    %esi,%eax
408338:	89 47 04             	mov    %eax,0x4(%edi)
40833b:	5f                   	pop    %edi
40833c:	5e                   	pop    %esi
40833d:	5b                   	pop    %ebx
40833e:	c9                   	leave
40833f:	c2 04 00             	ret    $0x4
408342:	e8 ca 5c 00 00       	call   0x40e011
408347:	cc                   	int3
408348:	8b ff                	mov    %edi,%edi
40834a:	55                   	push   %ebp
40834b:	8b ec                	mov    %esp,%ebp
40834d:	8b 4d 08             	mov    0x8(%ebp),%ecx
408350:	8d 45 10             	lea    0x10(%ebp),%eax
408353:	8b 55 0c             	mov    0xc(%ebp),%edx
408356:	50                   	push   %eax
408357:	8b 49 10             	mov    0x10(%ecx),%ecx
40835a:	e8 e9 f0 ff ff       	call   0x407448
40835f:	59                   	pop    %ecx
408360:	5d                   	pop    %ebp
408361:	c3                   	ret
408362:	cc                   	int3
408363:	cc                   	int3
408364:	cc                   	int3
408365:	cc                   	int3
408366:	cc                   	int3
408367:	cc                   	int3
408368:	cc                   	int3
408369:	cc                   	int3
40836a:	cc                   	int3
40836b:	cc                   	int3
40836c:	cc                   	int3
40836d:	cc                   	int3
40836e:	cc                   	int3
40836f:	cc                   	int3
408370:	6a 2a                	push   $0x2a
408372:	e8 c5 e1 ff ff       	call   0x40653c
408377:	c3                   	ret
408378:	cc                   	int3
408379:	cc                   	int3
40837a:	cc                   	int3
40837b:	cc                   	int3
40837c:	cc                   	int3
40837d:	cc                   	int3
40837e:	cc                   	int3
40837f:	cc                   	int3
408380:	8b ff                	mov    %edi,%edi
408382:	56                   	push   %esi
408383:	8b f1                	mov    %ecx,%esi
408385:	6a 01                	push   $0x1
408387:	6a 01                	push   $0x1
408389:	8b 4e 08             	mov    0x8(%esi),%ecx
40838c:	e8 30 e8 ff ff       	call   0x406bc1
408391:	8b 4e 08             	mov    0x8(%esi),%ecx
408394:	6a 00                	push   $0x0
408396:	e8 f5 e6 ff ff       	call   0x406a90
40839b:	5e                   	pop    %esi
40839c:	c3                   	ret
40839d:	cc                   	int3
40839e:	cc                   	int3
40839f:	cc                   	int3
4083a0:	6a 20                	push   $0x20
4083a2:	b8 d2 ef 40 00       	mov    $0x40efd2,%eax
4083a7:	e8 a2 62 00 00       	call   0x40e64e
4083ac:	89 4d ec             	mov    %ecx,-0x14(%ebp)
4083af:	6a 00                	push   $0x0
4083b1:	ff 15 34 20 41 00    	call   *0x412034
4083b7:	8b d8                	mov    %eax,%ebx
4083b9:	85 db                	test   %ebx,%ebx
4083bb:	0f 84 c1 00 00 00    	je     0x408482
4083c1:	a1 30 20 41 00       	mov    0x412030,%eax
4083c6:	33 c9                	xor    %ecx,%ecx
4083c8:	88 4d d4             	mov    %cl,-0x2c(%ebp)
4083cb:	89 45 d8             	mov    %eax,-0x28(%ebp)
4083ce:	89 5d dc             	mov    %ebx,-0x24(%ebp)
4083d1:	89 4d fc             	mov    %ecx,-0x4(%ebp)
4083d4:	89 4d e0             	mov    %ecx,-0x20(%ebp)
4083d7:	89 4d e4             	mov    %ecx,-0x1c(%ebp)
4083da:	89 4d e8             	mov    %ecx,-0x18(%ebp)
4083dd:	68 00 02 00 00       	push   $0x200
4083e2:	8d 4d e0             	lea    -0x20(%ebp),%ecx
4083e5:	c6 45 fc 01          	movb   $0x1,-0x4(%ebp)
4083e9:	e8 ff f4 ff ff       	call   0x4078ed
4083ee:	8b 75 e4             	mov    -0x1c(%ebp),%esi
4083f1:	8b 7d e0             	mov    -0x20(%ebp),%edi
4083f4:	2b f7                	sub    %edi,%esi
4083f6:	d1 fe                	sar    $1,%esi
4083f8:	8d 45 f0             	lea    -0x10(%ebp),%eax
4083fb:	89 75 f0             	mov    %esi,-0x10(%ebp)
4083fe:	50                   	push   %eax
4083ff:	57                   	push   %edi
408400:	56                   	push   %esi
408401:	53                   	push   %ebx
408402:	ff 15 2c 20 41 00    	call   *0x41202c
408408:	85 c0                	test   %eax,%eax