"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "libisofs/util.h" between
xorriso-1.5.2.tar.gz and xorriso-1.5.4.tar.gz

About: GNU xorriso creates, loads, manipulates and writes ISO 9660 filesystem images with Rock Ridge extensions. It is suitable for incremental data backup and for production of bootable ISO 9660 images. GNU xorriso is a statical compilation of the libraries libburn, libisofs, libisoburn, and libjte.

util.h  (xorriso-1.5.2):util.h  (xorriso-1.5.4)
skipping to change at line 58 skipping to change at line 58
/** /**
* Convert the charset encoding of a given string. * Convert the charset encoding of a given string.
* *
* @param input * @param input
* Input string * Input string
* @param icharset * @param icharset
* Input charset. Must be supported by iconv * Input charset. Must be supported by iconv
* @param ocharset * @param ocharset
* Output charset. Must be supported by iconv * Output charset. Must be supported by iconv
* @param output * @param output
* Location where the pointer to the ouput string will be stored * Location where the pointer to the output string will be stored
* @return * @return
* 1 on success, < 0 on error * 1 on success, < 0 on error
*/ */
int strconv(const char *input, const char *icharset, const char *ocharset, int strconv(const char *input, const char *icharset, const char *ocharset,
char **output); char **output);
/* Like strconv but processing len input bytes rather than strlen(input) /* Like strconv but processing len input bytes rather than strlen(input)
*/ */
int strnconv(const char *str, const char *icharset, const char *ocharset, int strnconv(const char *str, const char *icharset, const char *ocharset,
size_t len, char **output); size_t len, char **output);
skipping to change at line 83 skipping to change at line 83
size_t len, char **output, size_t *out_len); size_t len, char **output, size_t *out_len);
/** /**
* Convert a given string from any input charset to ASCII * Convert a given string from any input charset to ASCII
* *
* @param icharset * @param icharset
* Input charset. Must be supported by iconv * Input charset. Must be supported by iconv
* @param input * @param input
* Input string * Input string
* @param output * @param output
* Location where the pointer to the ouput string will be stored * Location where the pointer to the output string will be stored
* @return * @return
* 1 on success, < 0 on error * 1 on success, < 0 on error
*/ */
int str2ascii(const char *icharset, const char *input, char **output); int str2ascii(const char *icharset, const char *input, char **output);
/** /**
* Convert a given string from any input charset to UCS-2BE charset, * Convert a given string from any input charset to UCS-2BE charset,
* used for Joliet file identifiers. * used for Joliet file identifiers.
* *
* @param icharset * @param icharset
* Input charset. Must be supported by iconv * Input charset. Must be supported by iconv
* @param input * @param input
* Input string * Input string
* @param output * @param output
* Location where the pointer to the ouput string will be stored * Location where the pointer to the output string will be stored
* @return * @return
* 1 on success, < 0 on error * 1 on success, < 0 on error
*/ */
int str2ucs(const char *icharset, const char *input, uint16_t **output); int str2ucs(const char *icharset, const char *input, uint16_t **output);
/** /**
* Convert a given string from any input charset to UTF-16BE charset, * Convert a given string from any input charset to UTF-16BE charset,
* used for HFS+ file identifiers. * used for HFS+ file identifiers.
* (UTF-16 differs from older UCS-2 by having multi word characters.) * (UTF-16 differs from older UCS-2 by having multi word characters.)
* *
* @param icharset * @param icharset
* Input charset. Must be supported by iconv * Input charset. Must be supported by iconv
* @param input * @param input
* Input string * Input string
* @param output * @param output
* Location where the pointer to the ouput string will be stored * Location where the pointer to the output string will be stored
* @return * @return
* 1 on success, < 0 on error * 1 on success, < 0 on error
*/ */
int str2utf16be(const char *icharset, const char *input, uint16_t **output); int str2utf16be(const char *icharset, const char *input, uint16_t **output);
/** /**
* Create a level 1 directory identifier. * Create a level 1 directory identifier.
* *
* @param src * @param src
* The identifier, in ASCII encoding. * The identifier, in ASCII encoding.
skipping to change at line 261 skipping to change at line 261
/** /**
* Check whether utf_word is the first surrogate word of a pair. * Check whether utf_word is the first surrogate word of a pair.
* If so, change it to UTF-16 character '_'. * If so, change it to UTF-16 character '_'.
*/ */
void iso_handle_split_utf16(uint16_t *utf_word); void iso_handle_split_utf16(uint16_t *utf_word);
/** /**
* Convert a given input string to d-chars. * Convert a given input string to d-chars.
* @return * @return
* 1 on succes, < 0 error, 0 if input was null (output is set to null) * 1 on success, < 0 error, 0 if input was null (output is set to null)
*/ */
int str2d_char(const char *icharset, const char *input, char **output); int str2d_char(const char *icharset, const char *input, char **output);
int str2a_char(const char *icharset, const char *input, char **output); int str2a_char(const char *icharset, const char *input, char **output);
void iso_lsb(uint8_t *buf, uint32_t num, int bytes); void iso_lsb(uint8_t *buf, uint32_t num, int bytes);
void iso_lsb64(uint8_t *buf, uint64_t num);
void iso_msb(uint8_t *buf, uint32_t num, int bytes); void iso_msb(uint8_t *buf, uint32_t num, int bytes);
void iso_bb(uint8_t *buf, uint32_t num, int bytes); void iso_bb(uint8_t *buf, uint32_t num, int bytes);
/* An alternative to iso_lsb() which advances the write pointer /* An alternative to iso_lsb() which advances the write pointer
*/ */
int iso_lsb_to_buf(char **wpt, uint32_t value, int bytes, int flag); int iso_lsb_to_buf(char **wpt, uint32_t value, int bytes, int flag);
uint32_t iso_read_lsb(const uint8_t *buf, int bytes); uint32_t iso_read_lsb(const uint8_t *buf, int bytes);
uint32_t iso_read_msb(const uint8_t *buf, int bytes); uint32_t iso_read_msb(const uint8_t *buf, int bytes);
skipping to change at line 403 skipping to change at line 404
* @param include_item * @param include_item
* Function to select which elements to include in the array. It that takes * Function to select which elements to include in the array. It that takes
* a pointer to an element and returns 1 if the element should be included, * a pointer to an element and returns 1 if the element should be included,
* 0 if not. If you want to add all elements to the array, you can pass a * 0 if not. If you want to add all elements to the array, you can pass a
* NULL pointer. * NULL pointer.
* @param size * @param size
* If not null, will be filled with the number of elements in the array, * If not null, will be filled with the number of elements in the array,
* without counting the final NULL item. * without counting the final NULL item.
* @return * @return
* A sorted array with the contents of the tree, or NULL if there is not * A sorted array with the contents of the tree, or NULL if there is not
* enought memory to allocate the array. You should free(3) the array when * enough memory to allocate the array. You should free(3) the array when
* no more needed. Note that the array is NULL-terminated, and thus it * no more needed. Note that the array is NULL-terminated, and thus it
* has size + 1 length. * has size + 1 length.
*/ */
void **iso_rbtree_to_array(IsoRBTree *tree, int (*include_item)(void *), void **iso_rbtree_to_array(IsoRBTree *tree, int (*include_item)(void *),
size_t *size); size_t *size);
/** Predict the size of the array which gets returned by iso_rbtree_to_array(). /** Predict the size of the array which gets returned by iso_rbtree_to_array().
*/ */
size_t iso_rbtree_count_array(IsoRBTree *tree, size_t initial_count, size_t iso_rbtree_count_array(IsoRBTree *tree, size_t initial_count,
int (*include_item)(void *)); int (*include_item)(void *));
skipping to change at line 641 skipping to change at line 642
/* Like iso_clone_mem but first freeing *out if not NULL /* Like iso_clone_mem but first freeing *out if not NULL
*/ */
int iso_clone_mgtd_mem(char *in, char **out, size_t size); int iso_clone_mgtd_mem(char *in, char **out, size_t size);
/** Convert a text into a number of type double and multiply it by unit code /** Convert a text into a number of type double and multiply it by unit code
[kmgt] (2^10 to 2^40) or [s] (2048) or [d] (512). [kmgt] (2^10 to 2^40) or [s] (2048) or [d] (512).
(Also accepts capital letters.) (Also accepts capital letters.)
@param text Input like "42", "223062s", "3m" or "-1g" @param text Input like "42", "223062s", "3m" or "-1g"
@param flag Bitfield for control purposes: @param flag Bitfield for control purposes:
bit0= return -1 rathern than 0 on failure bit0= return -1 rather than 0 on failure
bit1= if scaled then compute the last byte of the last unit bit1= if scaled then compute the last byte of the last unit
@return The derived value @return The derived value
*/ */
off_t iso_scanf_io_size(char *text, int flag); off_t iso_scanf_io_size(char *text, int flag);
/* ------------------------------------------------------------------------- */ /* ------------------------------------------------------------------------- */
/* To avoid the need to include more system header files */ /* To avoid the need to include more system header files */
uint16_t iso_ntohs(uint16_t v); uint16_t iso_ntohs(uint16_t v);
uint16_t iso_htons(uint16_t v); uint16_t iso_htons(uint16_t v);
 End of changes. 8 change blocks. 
7 lines changed or deleted 8 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)