]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
posix: add getnameinfo(3) and assorted constants
authorMichael 'Mickey' Lauer <mickey@vanille-media.de>
Sat, 7 Jan 2012 11:52:36 +0000 (12:52 +0100)
committerJürg Billeter <j@bitron.ch>
Tue, 31 Jan 2012 12:17:55 +0000 (13:17 +0100)
vapi/posix.vapi

index 9aa8e53f06e0aee08986b45aaa8e79112dea02ea..9ddb431e36eb5010a24ef63a6d72b8864e70f3e0 100644 (file)
@@ -789,6 +789,20 @@ namespace Posix {
        [CCode (cheader_filename = "math.h")]
        public float scalbf (float x, float n);
 
+    [CCode (cheader_filename = "netdb.h")]
+    public const int NI_NAMEREQD;
+    [CCode (cheader_filename = "netdb.h")]
+    public const int NI_DGRAM;
+    [CCode (cheader_filename = "netdb.h")]
+    public const int NI_NOFQDN;
+    [CCode (cheader_filename = "netdb.h")]
+    public const int NI_NUMERICHOST;
+    [CCode (cheader_filename = "netdb.h")]
+    public const int NI_NUMERICSERV;
+
+    [CCode (cheader_filename = "netdb.h,sys/socket.h")]
+    public int getnameinfo (ref SockAddr sa, socklen_t salen, char[] node, char[] service, socklen_t servicelen, int flags);
+
        [CCode (cheader_filename = "poll.h", cname = "struct pollfd")]
        public struct pollfd {
                public int fd;