Ignore:
Timestamp:
Oct 12, 2022, 4:32:49 PM (19 months ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, ast-experimental, master
Children:
38cc59f
Parents:
a51b8f6
Message:

Added some missing headers and cleaned up some of the fork+exec stuff.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/meta/fork+exec.hfa

    ra51b8f6 r481f882  
    2828}
    2929
    30 static int true_main(const char * exec, char * env[]);
     30static int true_main(const char * path, char * env[]);
    3131
    3232static int do_wait(pid_t pid) {
     
    5555static void print_status(int wstatus) {
    5656        printf("Child status:\n");
    57         printf("    WIFEXITED   : %d\n", WIFEXITED(wstatus));
    58         printf("    WEXITSTATUS : %d\n", WEXITSTATUS(wstatus));
    59         printf("    WIFSIGNALED : %d\n", WIFSIGNALED(wstatus));
    60         printf("    WTERMSIG    : %d\n", WTERMSIG(wstatus));
    61         printf("    WCOREDUMP   : %d\n", WCOREDUMP(wstatus));
    62         printf("    WIFSTOPPED  : %d\n", WIFSTOPPED(wstatus));
    63         printf("    WSTOPSIG    : %d\n", WSTOPSIG(wstatus));
    64         printf("    WIFCONTINUED: %d\n", WIFCONTINUED(wstatus));
     57        printf("IFEXITED   : %d, ", WIFEXITED(wstatus));
     58        printf("EXITSTATUS : %d, ", WEXITSTATUS(wstatus));
     59        printf("IFSIGNALED : %d, ", WIFSIGNALED(wstatus));
     60        printf("TERMSIG    : %d, ", WTERMSIG(wstatus));
     61        printf("COREDUMP   : %d, ", WCOREDUMP(wstatus));
     62        printf("IFSTOPPED  : %d, ", WIFSTOPPED(wstatus));
     63        printf("STOPSIG    : %d, ", WSTOPSIG(wstatus));
     64        printf("IFCONTINUED: %d", WIFCONTINUED(wstatus));
     65        printf("\n");
     66        printf("\n");
    6567}
    6668
Note: See TracChangeset for help on using the changeset viewer.