5 #define STRING_COMMA_LEN(STR) (STR), (sizeof (STR) - 1)
8 main (int argc
, char **argv
)
10 char **ev
= &argv
[argc
+ 1];
13 const ElfW(Phdr
) *phdr
= NULL
;
16 int fd
= STDOUT_FILENO
;
19 while (*evp
++ != NULL
)
22 av
= (ElfW(auxv_t
) *) evp
;
24 for (; av
->a_type
!= AT_NULL
; ++av
)
28 phdr
= (const void *) av
->a_un
.a_val
;
31 phnum
= av
->a_un
.a_val
;
35 for (i
= 0; i
< phnum
; i
++, phdr
++)
36 if (phdr
->p_type
== PT_LOAD
)
39 syscall (SYS_write
, fd
, STRING_COMMA_LEN ("PASS\n"));
41 syscall (SYS_exit
, !loadnum
);
This page took 0.040124 seconds and 4 git commands to generate.