Changeset 025f9c5 for tests


Ignore:
Timestamp:
Sep 11, 2024, 1:33:42 PM (4 months ago)
Author:
Michael Brooks <mlbrooks@…>
Branches:
master
Children:
efe697d
Parents:
a35e342
Message:

Update 'fork+exec' test utility to be valid also in C and C++.

Location:
tests
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • tests/configs/parsebools.cfa

    ra35e342 r025f9c5  
    5050}
    5151
    52 int true_main( const char * path, char * env[] ) {
     52int true_main( const char * path, const char * env[] ) {
    5353        printf( "no arg:\n" );
    5454        if ( pid_t child = strict_fork(); child == 0 ) {
  • tests/configs/parsenums.cfa

    ra35e342 r025f9c5  
    6161}
    6262
    63 int true_main( const char * path, char * env[] ) {
     63int true_main( const char * path, const char * env[] ) {
    6464        printf( "no arg:\n" );
    6565        if ( pid_t child = strict_fork(); child == 0 ) {
  • tests/meta/fork+exec.cfa

    ra35e342 r025f9c5  
    3232
    3333
    34 int true_main(const char * path, char * env[]) {
     34int true_main(const char * path, const char * env[]) {
    3535        printf("no arg:\n");
    3636        if(pid_t child = strict_fork(); child == 0) {
  • tests/meta/fork+exec.hfa

    ra35e342 r025f9c5  
    2828}
    2929
    30 static int true_main(const char * path, char * env[]);
     30static int true_main(const char * path, const char * env[]);
    3131
    3232static int do_wait(pid_t pid) {
     
    7070        if(getenv("CFATEST_FORK_EXEC_TEXT")) return;
    7171
    72         char * env[] = { "CFATEST_FORK_EXEC_TEXT=1", 0p };
     72        const char * env[] = { "CFATEST_FORK_EXEC_TEXT=1", (char*)0 };
    7373        exit( true_main(path, env) );
    7474}
Note: See TracChangeset for help on using the changeset viewer.