view src/lib/hex-binary.h @ 8590:b9faf4db2a9f HEAD

Updated copyright notices to include year 2009.
author Timo Sirainen <tss@iki.fi>
date Tue, 06 Jan 2009 09:25:38 -0500
parents e4eb71ae8e96
children
line wrap: on
line source

#ifndef HEX_BINARY_H
#define HEX_BINARY_H

/* Convert binary to hex digits allocating return value from data stack */
const char *binary_to_hex(const unsigned char *data, size_t size);
const char *binary_to_hex_ucase(const unsigned char *data, size_t size);

/* Convert hex to binary. data and dest may point to same value.
   Returns 0 if all ok, -1 if data is invalid. */
int hex_to_binary(const char *data, buffer_t *dest);

#endif