Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
belle-sip
Commits
fd0a2df6
Commit
fd0a2df6
authored
Jan 22, 2013
by
Simon Morlat
Browse files
bugfixing on unix after windows merge.
parent
ca677643
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/belle_sip_loop.c
View file @
fd0a2df6
...
...
@@ -19,7 +19,6 @@
#include "belle-sip/belle-sip.h"
#include "belle_sip_internal.h"
#include <malloc.h>
#ifndef WIN32
#include <unistd.h>
...
...
@@ -69,11 +68,14 @@ static void belle_sip_source_to_poll(belle_sip_source_t *s, belle_sip_pollfd_t *
}
static
unsigned
int
belle_sip_source_get_revents
(
belle_sip_source_t
*
s
,
belle_sip_pollfd_t
*
pfd
){
return
belle_sip_poll_to_event
(
pfd
[
s
->
index
]);
return
belle_sip_poll_to_event
(
&
pfd
[
s
->
index
]);
}
#else
#include <malloc.h>
typedef
HANDLE
belle_sip_pollfd_t
;
static
void
belle_sip_source_to_poll
(
belle_sip_source_t
*
s
,
belle_sip_pollfd_t
*
pfd
,
int
i
){
...
...
src/port.c
View file @
fd0a2df6
...
...
@@ -98,6 +98,13 @@ const char *belle_sip_get_socket_error_string_from_code(int code){
#else
int
belle_sip_init_sockets
(){
return
0
;
}
void
belle_sip_uninit_sockets
(){
}
int
belle_sip_socket_set_nonblocking
(
belle_sip_socket_t
sock
){
return
fcntl
(
sock
,
F_SETFL
,
fcntl
(
sock
,
F_GETFL
)
|
O_NONBLOCK
);
}
...
...
src/port.h
View file @
fd0a2df6
...
...
@@ -46,6 +46,8 @@
* Socket abstraction layer
*/
int
belle_sip_init_sockets
(
void
);
void
belle_sip_uninit_sockets
(
void
);
int
belle_sip_socket_set_nonblocking
(
belle_sip_socket_t
sock
);
#if defined(WIN32)
...
...
@@ -75,8 +77,6 @@ static inline int inet_aton(const char *ip, struct in_addr *p){
#else
#define belle_sip_init_sockets() 0
#define belle_sip_uninit_sockets()
static
inline
void
close_socket
(
belle_sip_socket_t
s
){
close
(
s
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment