HomeAbout Us A-Z IndexSearch * Contact Us Register LoginPress Shop

The Open Brand -- Problem Reporting and Interpretations System


Problem Report 2545 Details

Help Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges

This page provides all information on Problem Report 2545.


Report 2545 Actions


    Problem Report Number 2545
    Submitter's Classification Test Suite problem
    State Resolved
    Resolution Test Suite Deficiency (TSD)
    Problem Resolution ID TSD.X.1314
    Raised 2009-01-05 14:33
    Updated 2009-01-05 20:26
    Published 2009-01-05 20:26
    Product Standard Internationalised System Calls and Libraries Extended V3 (UNIX 03)
    Certification Program The Open Brand certification program
    Test Suite VSTH version 5.4.8
    Test Identification /tset/PTHR.os/cfuncs/Mputc_unlocked/T.putc_unlocked 2
    Specification Base Definitions Issue 6
    Linked Problem Reports 2548
    Problem Summary Array overrun in /tset/PTHR.os/cfuncs/Mputc_unlocked/T.putc_unlocked
    Problem Text During the course of debugging the above error, it was discovered that the output of
    putc_unlocked was being written to file descriptor zero (stdout) instead of the intended pipe.
    When the tests execute putchar_unlocked_exectests, the write-end of the pipe should be
    passed as the ninth command line argument, but instead the empty string ("") is passed.
    This empty string is interpreted by putchar_unlocked_exectests as zero, resulting in the
    output going to standard output.

    From vsth/tset/PTHR.os/cfuncs/putchar_unlocked/putchar_unlocked.c:
    1. void
    2. t2_c1()
    3. {
    4. char *argv[4];
    5. char ascii_fd0[20];
    6. char ascii_fd1[20];
    7.
    8. argv[0] = execpath(TE_PATH);
    9. argv[1] = "1";
    10. argv[2] = strcpy(ascii_fd0, itoa(T2_fd[0]));
    11. argv[3] = strcpy(ascii_fd1, itoa(T2_fd[1]));
    12. argv[4] = NULL;
    13.
    14. (void) tet_exec(execpath(TE_PATH), argv, environ);
    15.
    16. exit(1);
    17. }

    Note that 'argv' is declared as an array of four elements (line 4), but five elements are written
    to it (line 12). On the Intel architecture, with GNU C compiler 4.2.1, this results in an empty
    string instead of the contents of ascii_fd1.
    Test Output ************************************************************************
    /tset/PTHR.os/cfuncs/Mputc_unlocked/T.putc_unlocked 2 Unresolved

    Test Description:
    If the _POSIX_THREAD_SAFE_FUNCTIONS option is supported:
    when the file referenced by stream does not support
    positioning requests or the stream was opened in append mode,
    then a call to putc_unlocked(c, stream) appends the character
    specified by c, converted to an unsigned char, to the output
    stream referenced by stream and returns c if successful.
    Posix Ref: Component PUTC_UNLOCKED Assertion 9945-1:1996 8.2.7.2,
    ANSI/ISO 9899-1990 7.9.7.8-2(C)

    Test Information:
    read unexpectedly failed, expected 38, got -1

    ************************************************************************

    Review Information

    Review Type TSMA Review
    Start Date 2009-01-05 14:33
    Last Updated 2009-01-05 17:45
    Completed 2009-01-05 17:45
    Status Complete
    Review Recommendation Test Suite Deficiency (TSD)
    Review Response This is accepted as a fault in the test suite.

    Review Type SA Review
    Start Date 2009-01-05 17:45
    Last Updated 2009-01-05 20:25
    Completed 2009-01-05 20:25
    Status Complete
    Review Resolution Test Suite Deficiency (TSD)
    Review Conclusion A test suite deficiency is granted.

    Problem Reporting System Options:

     

    Back   


Contact the Certification Authority