[IOT-2539] Clean implicit-function warning
authorGeorge Nash <george.nash@intel.com>
Tue, 1 Aug 2017 19:34:06 +0000 (12:34 -0700)
committerGeorge Nash <george.nash@intel.com>
Mon, 28 Aug 2017 23:18:39 +0000 (23:18 +0000)
commit0d5968bdca21de6e3f1185bae48d669243e1a911
tree0cbf9bb452150902fb98317130d6b5e589f86f30
parenta54db53f54b443af730573c19a5f37c132058e90
[IOT-2539] Clean implicit-function warning

pmutility.c code would give an implicit-funtion-declaration
warning when the usleep function was used. On linux the
usleep function is part of unistd.h which was already
included.

usleep is not exposed unless _DEFAULT_SOURCE or _BSD_SOURCE
is defined before including unistd.h. To prevent another warning
[-Wcpp] both macros are included. As directed in the glibc
release notes:
https://sourceware.org/glibc/wiki/Release/2.20#Packaging_Changes

Bug: https://jira.iotivity.org/browse/IOT-2539
Change-Id: I7002ef303ba685bda76f70590d7c9593435b4ba7
Signed-off-by: George Nash <george.nash@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/21707
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
(cherry picked from commit f00086bf5f66b31e77c7d11c2780d75cd0e95150)
resource/csdk/security/provisioning/src/pmutility.c