This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug stdio/16890] New: fwprintf does not print NULL pointers properly


https://sourceware.org/bugzilla/show_bug.cgi?id=16890

            Bug ID: 16890
           Summary: fwprintf does not print NULL pointers properly
           Product: glibc
           Version: 2.19
            Status: NEW
          Severity: minor
          Priority: P2
         Component: stdio
          Assignee: unassigned at sourceware dot org
          Reporter: james410 at cowgill dot org.uk

fwprintf (and associated wide printf functions) print "(" instead of "(nil)"
when passed a NULL pointer to a "%p" format string.

Test Program
----------------------
#include <stdio.h>
#include <wchar.h>

int main(void)
{
    fprintf(stderr, " fprintf: %p\n", NULL);
    fwprintf(stdout, L"fwprintf: %p\n", NULL);
    return 0;
}

Expected Results
----------------------
 fprintf: (nil)
fwprintf: (nil)

Actual Results
----------------------
 fprintf: (nil)
fwprintf: (

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]