re PR libstdc++/65909 (check_v3_target_namedlocale blows up on targets that don't...
authorSandra Loosemore <sandra@codesourcery.com>
Tue, 28 Apr 2015 02:40:56 +0000 (22:40 -0400)
committerSandra Loosemore <sandra@gcc.gnu.org>
Tue, 28 Apr 2015 02:40:56 +0000 (22:40 -0400)
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.

From-SVN: r222497

libstdc++-v3/ChangeLog
libstdc++-v3/testsuite/lib/libstdc++.exp

index be9364c4ec92a89c0cd14f4cee0b3cba9f534eb9..3580f39a453e838681e00eba2863a7f73062948b 100644 (file)
@@ -1,3 +1,10 @@
+2015-04-27  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/65909
+       * 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.
+
 2015-04-27  Federico Lenarduzzi  <federico.lenarduzzi@tallertechnologies.com>
            Jonathan Wakely  <jwakely@redhat.com>
 
index 6a6374a8e6baa951d71a9919fb20d15b1a1f9d64..d581a53e3c40e30d785d2dc0b8f24c33b43d5f22 100644 (file)
@@ -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));"