Commit 4c7a79dd authored by Christophe Massiot's avatar Christophe Massiot

Fixed compilation problems with OpenBSD.

parent 34487b0b
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* Collection of useful common types and macros definitions * Collection of useful common types and macros definitions
***************************************************************************** *****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN * Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: common.h,v 1.41 2001/09/28 09:57:08 massiot Exp $ * $Id: common.h,v 1.42 2001/10/22 12:28:53 massiot Exp $
* *
* Authors: Samuel Hocevar <sam@via.ecp.fr> * Authors: Samuel Hocevar <sam@via.ecp.fr>
* Vincent Seguin <seguin@via.ecp.fr> * Vincent Seguin <seguin@via.ecp.fr>
...@@ -206,6 +206,7 @@ struct pgrm_descriptor_s; ...@@ -206,6 +206,7 @@ struct pgrm_descriptor_s;
#else #else
# ifdef HAVE_VALLOC # ifdef HAVE_VALLOC
/* That's like using a hammer to kill a fly, but eh... */ /* That's like using a hammer to kill a fly, but eh... */
# include <unistd.h>
# define memalign(align,size) valloc(size) # define memalign(align,size) valloc(size)
# else # else
/* Assume malloc alignment is sufficient */ /* Assume malloc alignment is sufficient */
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
* modules. * modules.
***************************************************************************** *****************************************************************************
* Copyright (C) 1999, 2000, 2001 VideoLAN * Copyright (C) 1999, 2000, 2001 VideoLAN
* $Id: netutils.h,v 1.14 2001/05/30 17:03:11 sam Exp $ * $Id: netutils.h,v 1.15 2001/10/22 12:28:53 massiot Exp $
* *
* Authors: Vincent Seguin <seguin@via.ecp.fr> * Authors: Vincent Seguin <seguin@via.ecp.fr>
* Henri Fallon <henri@videolan.org> * Henri Fallon <henri@videolan.org>
...@@ -30,6 +30,7 @@ ...@@ -30,6 +30,7 @@
/***************************************************************************** /*****************************************************************************
* Prototypes * Prototypes
*****************************************************************************/ *****************************************************************************/
struct sockaddr_in;
int network_BuildLocalAddr ( struct sockaddr_in *, int, char * ); int network_BuildLocalAddr ( struct sockaddr_in *, int, char * );
int network_BuildRemoteAddr( struct sockaddr_in *, char * ); int network_BuildRemoteAddr( struct sockaddr_in *, char * );
int network_ChannelJoin ( int ); int network_ChannelJoin ( int );
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* modules_core.h : Module management functions used by the core application. * modules_core.h : Module management functions used by the core application.
***************************************************************************** *****************************************************************************
* Copyright (C) 2001 VideoLAN * Copyright (C) 2001 VideoLAN
* $Id: modules_core.h,v 1.3 2001/06/25 11:34:08 sam Exp $ * $Id: modules_core.h,v 1.4 2001/10/22 12:28:53 massiot Exp $
* *
* Authors: Samuel Hocevar <sam@zoy.org> * Authors: Samuel Hocevar <sam@zoy.org>
* *
...@@ -42,12 +42,16 @@ module_load( char * psz_filename, module_handle_t * handle ) ...@@ -42,12 +42,16 @@ module_load( char * psz_filename, module_handle_t * handle )
*handle = LoadLibrary( psz_filename ); *handle = LoadLibrary( psz_filename );
return( *handle == NULL ); return( *handle == NULL );
#else #elif defined(RTLD_NOW)
/* Do not open modules with RTLD_GLOBAL, or we are going to get namespace /* Do not open modules with RTLD_GLOBAL, or we are going to get namespace
* collisions when two modules have common public symbols */ * collisions when two modules have common public symbols */
*handle = dlopen( psz_filename, RTLD_NOW ); *handle = dlopen( psz_filename, RTLD_NOW );
return( *handle == NULL ); return( *handle == NULL );
#else
*handle = dlopen( psz_filename, DL_LAZY );
return( *handle == NULL );
#endif #endif
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment