endian.c File Reference

#include "globals.h"
#include "endian.h"

Functions


Function Documentation

int cl_bswap32 ( int  x  ) 

Swaps the byte order of a integer.

This function is a portable bswap implementation allowing explicit conversion to little-endian format (by a combination of cl_bswap32() and htonl())

Note that this function will work correctly with 32bit and larger int data types.

Parameters:
x The integer whose bytes are to be reordered.
Returns:
The reordered integer.

Referenced by process_fd().


Generated on Sun Feb 28 18:08:04 2010 for CWB by  doxygen 1.6.1