From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E40D73972416; Thu, 21 May 2020 11:40:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E40D73972416 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1590061209; bh=SuwoKm+Wu/9VxLDq52qpfmcXsdoFVRRwwsko8eQdcCc=; h=From:To:Subject:Date:From; b=oH0yBwk6jITHFChLpyMmX715gbdQxeUohfbh106A+rj65IEe0RakbThYB3//mfyyc iiGbQuEOighoMvSraXlO7jOZ9HNmy0iyNn51r2dMBvaL9tBCcUrgxRF6ybTT/8YGxr XREFdFM6NEw/BrczKlgf/iOuGQzEY/BtMc6ZaRCs= From: "daffra.claudio at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/95257] New: valgrind gives me error when wprintf in stderr Date: Thu, 21 May 2020 11:40:09 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 7.5.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: daffra.claudio at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 May 2020 11:40:10 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95257 Bug ID: 95257 Summary: valgrind gives me error when wprintf in stderr Product: gcc Version: 7.5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: daffra.claudio at gmail dot com Target Milestone: --- this simple program gives me error when i check with valgrind, this happen in stderr only. valgrind --leak-check=3Dfull --show-leak-kinds=3Dall ./x #include #include int main ( void ) { fwprintf ( stderr , L"valgrind error\n" ) ; return 0 ; } valgrind error : =3D=3D7438=3D=3D Memcheck, a memory error detector =3D=3D7438=3D=3D Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward e= t al. =3D=3D7438=3D=3D Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyri= ght info =3D=3D7438=3D=3D Command: ./x =3D=3D7438=3D=3D=20 valgrind error=3D=3D7438=3D=3D=20 =3D=3D7438=3D=3D HEAP SUMMARY: =3D=3D7438=3D=3D in use at exit: 5,120 bytes in 2 blocks =3D=3D7438=3D=3D total heap usage: 2 allocs, 0 frees, 5,120 bytes allocat= ed =3D=3D7438=3D=3D=20 =3D=3D7438=3D=3D 1,024 bytes in 1 blocks are still reachable in loss record= 1 of 2 =3D=3D7438=3D=3D at 0x4C2FB0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) =3D=3D7438=3D=3D by 0x4EBA18B: _IO_file_doallocate (filedoalloc.c:101) =3D=3D7438=3D=3D by 0x4EBB88C: _IO_wfile_doallocate (wfiledoalloc.c:70) =3D=3D7438=3D=3D by 0x4ECA378: _IO_doallocbuf (genops.c:365) =3D=3D7438=3D=3D by 0x4EC26C7: _IO_wfile_overflow (wfileops.c:430) =3D=3D7438=3D=3D by 0x4EBFD51: __woverflow (wgenops.c:217) =3D=3D7438=3D=3D by 0x4EBFD51: _IO_wdefault_xsputn (wgenops.c:317) =3D=3D7438=3D=3D by 0x4EC2AD0: _IO_wfile_xsputn (wfileops.c:1012) =3D=3D7438=3D=3D by 0x4EA7089: buffered_vfprintf (vfprintf.c:2343) =3D=3D7438=3D=3D by 0x4EA40FD: vfwprintf (vfprintf.c:1301) =3D=3D7438=3D=3D by 0x4EBEA23: fwprintf (fwprintf.c:33) =3D=3D7438=3D=3D by 0x1086A8: main (in /home/claudio/x) =3D=3D7438=3D=3D=20 =3D=3D7438=3D=3D 4,096 bytes in 1 blocks are still reachable in loss record= 2 of 2 =3D=3D7438=3D=3D at 0x4C2FB0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) =3D=3D7438=3D=3D by 0x4EBB858: _IO_wfile_doallocate (wfiledoalloc.c:79) =3D=3D7438=3D=3D by 0x4ECA378: _IO_doallocbuf (genops.c:365) =3D=3D7438=3D=3D by 0x4EC26C7: _IO_wfile_overflow (wfileops.c:430) =3D=3D7438=3D=3D by 0x4EBFD51: __woverflow (wgenops.c:217) =3D=3D7438=3D=3D by 0x4EBFD51: _IO_wdefault_xsputn (wgenops.c:317) =3D=3D7438=3D=3D by 0x4EC2AD0: _IO_wfile_xsputn (wfileops.c:1012) =3D=3D7438=3D=3D by 0x4EA7089: buffered_vfprintf (vfprintf.c:2343) =3D=3D7438=3D=3D by 0x4EA40FD: vfwprintf (vfprintf.c:1301) =3D=3D7438=3D=3D by 0x4EBEA23: fwprintf (fwprintf.c:33) =3D=3D7438=3D=3D by 0x1086A8: main (in /home/claudio/x) =3D=3D7438=3D=3D=20 =3D=3D7438=3D=3D LEAK SUMMARY: =3D=3D7438=3D=3D definitely lost: 0 bytes in 0 blocks =3D=3D7438=3D=3D indirectly lost: 0 bytes in 0 blocks =3D=3D7438=3D=3D possibly lost: 0 bytes in 0 blocks =3D=3D7438=3D=3D still reachable: 5,120 bytes in 2 blocks =3D=3D7438=3D=3D suppressed: 0 bytes in 0 blocks =3D=3D7438=3D=3D=20 =3D=3D7438=3D=3D For counts of detected and suppressed errors, rerun with: = -v =3D=3D7438=3D=3D ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 fro= m 0) compiler : gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04).=