summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorKevin Harwell <kharwell@digium.com>2014-01-28 20:47:15 +0000
committerKevin Harwell <kharwell@digium.com>2014-01-28 20:47:15 +0000
commit01a537d515af85c50ae608eb8486f42da7b84101 (patch)
tree2763434fe922fde8320cd528f38a9f5ddf1bc1fa /include
parent3eae87fdfe39f988674f1faeecb3ce592b514962 (diff)
res_pjsip,compat: INFINITY and NAN undefined
On some systems the values for INFINITY and NAN are not defined thus causing a build error on those systems. Added definitions for those if they had not previously been defined. (closes issue ASTERISK-23056) Reported by: capouch Patches: inf-nan-patch.txt uploaded by capouch (license 6564) ........ Merged revisions 406788 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@406789 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'include')
-rw-r--r--include/asterisk/compat.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/asterisk/compat.h b/include/asterisk/compat.h
index e5147cbde..c9c99c150 100644
--- a/include/asterisk/compat.h
+++ b/include/asterisk/compat.h
@@ -224,4 +224,12 @@ float roundf(float x);
#endif
#endif
+#ifndef INFINITY
+#define INFINITY (1.0/0.0)
+#endif
+
+#ifndef NAN
+#define NAN (0.0/0.0)
+#endif
+
#endif