public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [libstdc++, committed] fix PR65909
@ 2015-04-28  4:18 Sandra Loosemore
  0 siblings, 0 replies; only message in thread
From: Sandra Loosemore @ 2015-04-28  4:18 UTC (permalink / raw)
  To: GCC Patches; +Cc: libstdc++, Jonathan Wakely

[-- Attachment #1: Type: text/plain, Size: 485 bytes --]

This patch works around a libstdc++ testsuite issue:  the generated 
program that tests for the availability of named locales dereferences 
invalid pointers on targets that don't allow command-line arguments to 
be passed.  (In particular, I ran into this with a simulator for an 
embedded target that produces a ton of verbose error messages when it 
hits an invalid memory reference.)  Jonathan already approved the fix in 
the issue, so I've gone ahead and checked it in.

-Sandra


[-- Attachment #2: nlocale.log --]
[-- Type: text/x-log, Size: 267 bytes --]

2015-04-27  Sandra Loosemore  <sandra@codesourcery.com>

	PR libstdc++/65909

	libstdc++-v3/
	* testsuite/lib/libstdc++.exp (check_v3_target_namedlocale):
	Make the generated test program fail gracefully if the target
	doesn't	support passing command-line arguments.

[-- Attachment #3: nlocale.patch --]
[-- Type: text/x-patch, Size: 674 bytes --]

Index: libstdc++-v3/testsuite/lib/libstdc++.exp
===================================================================
--- libstdc++-v3/testsuite/lib/libstdc++.exp	(revision 222496)
+++ libstdc++-v3/testsuite/lib/libstdc++.exp	(working copy)
@@ -901,6 +901,11 @@ proc check_v3_target_namedlocale { args 
       puts $f "using namespace std;"	
       puts $f "int main (int argc, char** argv)"
       puts $f "{"
+      puts $f "  if (argc < 2)"
+      puts $f "  {"
+      puts $f "    printf(\"locale support test not supported\\n\");"
+      puts $f "    return 1;"
+      puts $f "  }"	
       puts $f "  try"	
       puts $f "  {"
       puts $f "    locale(*(argv + 1));"

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-04-28  2:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-28  4:18 [libstdc++, committed] fix PR65909 Sandra Loosemore

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).