[Olsr-cvs] olsrd-current/src olsr_types.h,1.9,1.10

Bernd Petrovitsch (spam-protected)
Wed Oct 24 15:51:13 CEST 2007


Update of /cvsroot/olsrd/olsrd-current/src
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18284/src

Modified Files:
	olsr_types.h 
Log Message:
* unified typedefs of olsr_{u,}{8,16,32}_t: It builds that way on Linux and Windows and *BSD had it before. That leaves MacOSx for someone to test.

Index: olsr_types.h
===================================================================
RCS file: /cvsroot/olsrd/olsrd-current/src/olsr_types.h,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** olsr_types.h	5 Sep 2007 16:11:11 -0000	1.9
--- olsr_types.h	24 Oct 2007 13:51:11 -0000	1.10
***************
*** 49,53 ****
  
  /* types */
! #include <sys/types.h>
  
  typedef enum {
--- 49,54 ----
  
  /* types */
! #include <inttypes.h>
! 
  
  typedef enum {
***************
*** 56,86 ****
  } olsr_bool;
  
! #if defined linux || defined __MacOSX__
! 
! typedef u_int8_t        olsr_u8_t;
! typedef u_int16_t       olsr_u16_t;
! typedef u_int32_t       olsr_u32_t;
! typedef int8_t          olsr_8_t;
! typedef int16_t         olsr_16_t;
! typedef int32_t         olsr_32_t;
! 
! #elif defined __FreeBSD__ || defined __NetBSD__ || defined __OpenBSD__
  
! typedef	uint8_t		olsr_u8_t;
! typedef uint16_t       	olsr_u16_t;
! typedef uint32_t       	olsr_u32_t;
  typedef int8_t          olsr_8_t;
  typedef int16_t         olsr_16_t;
  typedef int32_t         olsr_32_t;
  
- #elif defined WIN32
- 
- typedef unsigned char   olsr_u8_t;
- typedef unsigned short  olsr_u16_t;
- typedef unsigned int    olsr_u32_t;
- typedef char            olsr_8_t;
- typedef short           olsr_16_t;
- typedef int             olsr_32_t;
- 
  #else
  #       error "Unsupported system"
--- 57,69 ----
  } olsr_bool;
  
! #if defined linux || defined __MacOSX__ || defined WIN32 || defined __FreeBSD__ || defined __NetBSD__ || defined __OpenBSD__
  
! typedef uint8_t         olsr_u8_t;
! typedef uint16_t        olsr_u16_t;
! typedef uint32_t        olsr_u32_t;
  typedef int8_t          olsr_8_t;
  typedef int16_t         olsr_16_t;
  typedef int32_t         olsr_32_t;
  
  #else
  #       error "Unsupported system"





More information about the Olsr-cvs mailing list