0001 REALLOC(3)
0002 ==========
0003 :doctype: manpage
0004
0005
0006 NAME
0007 ----
0008 Brealloc - Reallocate buffer to given size
0009
0010
0011 SYNOPSIS
0012 --------
0013
0014 #include <ubf.h>
0015
0016
0017 UBFH * Brealloc (UBFH *'p_ub', BFLDOCC 'f', BFLDLEN 'v');
0018
0019 Link with '-lubf -lnstd -lm -lpthread'
0020
0021 DESCRIPTION
0022 -----------
0023 Reallocates UBF buffer to store the number of fields of 'f' with total data
0024 length of 'v' bytes, length must include zero terminator byte for strings.
0025
0026
0027 RETURN VALUE
0028 ------------
0029 On success, *Brealloc()* returns pointer to UBF buffer; on error, NULL is
0030 returned, with *Berror* set to indicate the error.
0031
0032 ERRORS
0033 ------
0034 Note that *Bstrerror()* returns generic error message plus custom message
0035 with debug info from last function call.
0036
0037 *BEINVAL* Buffer is shorter than currently bytes used, or the total size
0038 of bigger than *MAXUBFLEN*.
0039
0040 *BMALLOC* Malloc failed.
0041
0042 EXAMPLE
0043 -------
0044 See *ubftest/test_mem.c* for sample code.
0045
0046 BUGS
0047 ----
0048 Report bugs to support@mavimax.com
0049
0050 SEE ALSO
0051 --------
0052 *Bfree(3)* *Balloc(3)* *Binit(3)* *Bused(3)* *Bneeded(3)*
0053
0054 COPYING
0055 -------
0056 (C) Mavimax, Ltd
0057