@@ -20,22 +20,22 @@ ${acceptloop}:
2020 / * Socket file descriptor is placed in EBP * /
2121
2222 / * sock = socket(AF_INET , SOCK_STREAM , 0 ) * /
23- ${i386.linux. push ( 0 )}
24- ${i386.linux. push ( 'SOCK_STREAM' )}
25- ${i386.linux. push ( 'AF_INET' )}
23+ ${i386. push ( 0 )}
24+ ${i386. push ( 'SOCK_STREAM' )}
25+ ${i386. push ( 'AF_INET' )}
2626 ${i386.linux. syscall ( 'SYS_socketcall' , 'SYS_socketcall_socket' , 'esp' )}
2727
28- ${i386.linux. mov ( 'esi' , 'eax' )} / * keep socket fd * /
28+ ${i386. mov ( 'esi' , 'eax' )} / * keep socket fd * /
2929
3030 / * bind(sock , &addr , sizeof addr) ; // sizeof addr == 0x10 */
31- ${i386.linux. push ( 0 )}
31+ ${i386. push ( 0 )}
3232 / * ${htons(port)} == htons(${port}) * /
33- ${i386.linux. push ( 'AF_INET | (%d << 16)' % htons(port))}
34- ${i386.linux. mov ( 'ecx' , 'esp' )}
33+ ${i386. push ( 'AF_INET | (%d << 16)' % htons(port))}
34+ ${i386. mov ( 'ecx' , 'esp' )}
3535
36- ${i386.linux. push ( 0x10 )} / * sizeof addr * /
37- ${i386.linux. push ( 'ecx' )} / * &addr * /
38- ${i386.linux. push ( 'eax' )} / * sock * /
36+ ${i386. push ( 0x10 )} / * sizeof addr * /
37+ ${i386. push ( 'ecx' )} / * &addr * /
38+ ${i386. push ( 'eax' )} / * sock * /
3939 ${i386.linux. syscall ( 'SYS_socketcall' , 'SYS_socketcall_bind' , 'esp' )}
4040
4141 / * listen(sock , whatever) * /
@@ -44,17 +44,17 @@ ${acceptloop}:
4444
4545${looplabel}:
4646 / * accept(sock , NULL , NULL) * /
47- ${i386.linux. push ( 0x0 )}
48- ${i386.linux. push ( 'esi' )} / * sock * /
47+ ${i386. push ( 0x0 )}
48+ ${i386. push ( 'esi' )} / * sock * /
4949 ${i386.linux. syscall ( 'SYS_socketcall' , 'SYS_socketcall_accept' , 'esp' )}
5050
51- ${i386.linux. mov ( 'ebp' , 'eax' )} / * keep in - coming socket fd * /
51+ ${i386. mov ( 'ebp' , 'eax' )} / * keep in - coming socket fd * /
5252
5353 ${i386.linux. syscall ( 'SYS_fork' )}
5454 xchg eax , edi
5555
5656 test edi , edi
57- ${i386.linux. mov ( 'ebx' , 'ebp' )}
57+ ${i386. mov ( 'ebx' , 'ebp' )}
5858 cmovz ebx , esi / * on child we close the server sock instead * /
5959
6060 / * close(sock) * /
0 commit comments