assert-h: work around 'verify' incompatibility
[pspp] / lib / spawnattr_getschedpolicy.c
index d0f81e16427113a3943c13c7f74a82484deb3dfb..3415ca54f354948308971f1fd888d426b4840f27 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2009-2011 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    This program is free software: you can redistribute it and/or modify
@@ -26,8 +26,11 @@ int
 posix_spawnattr_getschedpolicy (const posix_spawnattr_t *attr,
                                 int *schedpolicy)
 {
+  /* Do nothing if POSIX_SPAWN_SETSCHEDULER is unsupported.  */
+#if POSIX_SPAWN_SETSCHEDULER != 0
   /* Copy the scheduling policy.  */
   *schedpolicy = attr->_policy;
+#endif
 
   return 0;
 }