2019-09-01 François Dumont <fdumont@gcc.gnu.org>
authorFrançois Dumont <fdumont@gcc.gnu.org>
Sun, 1 Sep 2019 20:11:42 +0000 (20:11 +0000)
committerFrançois Dumont <fdumont@gcc.gnu.org>
Sun, 1 Sep 2019 20:11:42 +0000 (20:11 +0000)
* testsuite_files/util/testsuite_performance.h
(resource_counter::start): Ignore unused malloc(0) result.

From-SVN: r275284

libstdc++-v3/ChangeLog
libstdc++-v3/testsuite/util/testsuite_performance.h

index 9156e3b1bf0685e6f2e1bc57d530006d6e00ef77..a3d3884665b8eeb93aac7c0d570517894233f41e 100644 (file)
@@ -1,3 +1,8 @@
+2019-09-01  François Dumont  <fdumont@gcc.gnu.org>
+
+       * testsuite_files/util/testsuite_performance.h
+       (resource_counter::start): Ignore unused malloc(0) result.
+
 2019-09-01  Gerald Pfeifer  <gerald@pfeifer.com>
 
        * doc/xml/manual/policy_data_structures_biblio.xml (COM: Component
index fd163914d99adaf6de4ea65cf4c9b03b959d3004..086dcc7ada431e685d2b949979af7852feb847cb 100644 (file)
@@ -167,7 +167,7 @@ namespace __gnu_test
     {
       if (getrusage(who, &rusage_begin) != 0 )
        memset(&rusage_begin, 0, sizeof(rusage_begin));
-      malloc(0); // Needed for some implementations.
+      void* p __attribute__((unused)) = malloc(0); // Needed for some implementations.
       allocation_begin = mallinfo();
     }