X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;ds=sidebyside;f=lib%2Fspawnattr_getschedpolicy.c;h=248e05a86445545c6dd0a47c688def1406a30678;hb=b3c3b08eab509ef08c9303b05375088575f8cc1b;hp=58d44b754861630876fb07096196d87dd24a5329;hpb=441aa3044f43e5572f58c354f01e6bc070acd5c7;p=gnulib.git diff --git a/lib/spawnattr_getschedpolicy.c b/lib/spawnattr_getschedpolicy.c index 58d44b754..248e05a86 100644 --- a/lib/spawnattr_getschedpolicy.c +++ b/lib/spawnattr_getschedpolicy.c @@ -1,4 +1,4 @@ -/* Copyright (C) 2000 Free Software Foundation, Inc. +/* Copyright (C) 2000, 2009-2010 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; }