diff options
Diffstat (limited to 'gcc/ada/libgnat/g-socthi.adb')
-rw-r--r-- | gcc/ada/libgnat/g-socthi.adb | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/gcc/ada/libgnat/g-socthi.adb b/gcc/ada/libgnat/g-socthi.adb index 68c82e2..5d86993 100644 --- a/gcc/ada/libgnat/g-socthi.adb +++ b/gcc/ada/libgnat/g-socthi.adb @@ -74,17 +74,17 @@ package body GNAT.Sockets.Thin is function Syscall_Recv (S : C.int; Msg : System.Address; - Len : C.int; - Flags : C.int) return C.int; + Len : C.size_t; + Flags : C.int) return System.CRTL.ssize_t; pragma Import (C, Syscall_Recv, "recv"); function Syscall_Recvfrom (S : C.int; Msg : System.Address; - Len : C.int; + Len : C.size_t; Flags : C.int; From : System.Address; - Fromlen : not null access C.int) return C.int; + Fromlen : not null access C.int) return System.CRTL.ssize_t; pragma Import (C, Syscall_Recvfrom, "recvfrom"); function Syscall_Recvmsg @@ -102,10 +102,10 @@ package body GNAT.Sockets.Thin is function Syscall_Sendto (S : C.int; Msg : System.Address; - Len : C.int; + Len : C.size_t; Flags : C.int; To : System.Address; - Tolen : C.int) return C.int; + Tolen : C.int) return System.CRTL.ssize_t; pragma Import (C, Syscall_Sendto, "sendto"); function Syscall_Socket @@ -250,14 +250,14 @@ package body GNAT.Sockets.Thin is function C_Recv (S : C.int; Msg : System.Address; - Len : C.int; + Len : C.size_t; Flags : C.int) return C.int is Res : C.int; begin loop - Res := Syscall_Recv (S, Msg, Len, Flags); + Res := C.int (Syscall_Recv (S, Msg, Len, Flags)); exit when SOSC.Thread_Blocking_IO or else Res /= Failure or else Non_Blocking_Socket (S) @@ -275,7 +275,7 @@ package body GNAT.Sockets.Thin is function C_Recvfrom (S : C.int; Msg : System.Address; - Len : C.int; + Len : C.size_t; Flags : C.int; From : System.Address; Fromlen : not null access C.int) return C.int @@ -284,7 +284,7 @@ package body GNAT.Sockets.Thin is begin loop - Res := Syscall_Recvfrom (S, Msg, Len, Flags, From, Fromlen); + Res := C.int (Syscall_Recvfrom (S, Msg, Len, Flags, From, Fromlen)); exit when SOSC.Thread_Blocking_IO or else Res /= Failure or else Non_Blocking_Socket (S) @@ -350,7 +350,7 @@ package body GNAT.Sockets.Thin is function C_Sendto (S : C.int; Msg : System.Address; - Len : C.int; + Len : C.size_t; Flags : C.int; To : System.Address; Tolen : C.int) return C.int @@ -359,7 +359,7 @@ package body GNAT.Sockets.Thin is begin loop - Res := Syscall_Sendto (S, Msg, Len, Flags, To, Tolen); + Res := C.int (Syscall_Sendto (S, Msg, Len, Flags, To, Tolen)); exit when SOSC.Thread_Blocking_IO or else Res /= Failure or else Non_Blocking_Socket (S) |