This graph shows which files directly or indirectly include this file:
Go to the source code of this file.
Data Structures | |
struct | _a_buf |
Buffer structure. More... | |
Typedefs | |
typedef _a_buf | ABuf |
Buffer structure. | |
Functions | |
ABuf * | buf_new (unsigned int len) |
Allocate a new buffer. | |
ABuf * | buf_free (ABuf *buf) |
Free a buffer_handle_type. | |
ABuf * | buf_check (ABuf *buf, unsigned int len) |
Check that the buffer is at least 'len' bytes. | |
ABuf * | buf_strcat (ABuf *buf, char *s) |
append the string 's' to the buffer. | |
ABuf * | buf_strcpy (ABuf *buf, char *s) |
Copy the string 's' into the buffer, replacing whatever's there. | |
ABuf * | buf_str_shrinkbyone (ABuf *buf) |
Shrinks the char string in the buffer by one character. | |
ABuf * | buf_terminate (ABuf *buf) |
Ensure that the last char in the buffer contains '\0'. |
Definition in file buf.h.
|
Check that the buffer is at least 'len' bytes. If it is not at least 'len' bytes long, a new buffer is allocated. Returns a pointer to either the original or the new buffer. Always use: buf = buf_check(buf, len);
Definition at line 112 of file buf.c. References _a_buf::b_dat, _a_buf::b_len, buf_free(), and buf_new(). Referenced by buf_strcat(), buf_strcpy(), export_html_dialog_show(), my_DBform_to_url(), pg_DBform_to_url(), send_callback(), xp_DBform_to_url(), and xp_DBget_field_value_attrib(). |
|
Free a buffer_handle_type.
Definition at line 90 of file buf.c. References _a_buf::b_dat. Referenced by buf_check(), db_connect_dialog_reconnect(), disconnect_first(), export_as_html(), export_as_text(), export_text_dialog_create(), frm_save_file(), gui_load_query_from_file(), gui_send_query(), on_databaseDisconnect_activate(), on_queryImportDlgOkBtn_clicked(), query_add(), query_import_dialog_create(), query_save_dialog_create(), result_export(), send_callback(), and ws_save_file(). |
|
Allocate a new buffer. allocsize() is used to calculate the buffer size, so the returned buffer may be larger than the requested size.
Definition at line 74 of file buf.c. References allocsize(), _a_buf::b_dat, and _a_buf::b_len. Referenced by buf_check(), buf_strcat(), buf_strcpy(), db_connect_dialog_reconnect(), disconnect_first(), export_as_html(), export_as_text(), frm_save_file(), gui_load_query_from_file(), gui_send_query(), on_databaseDisconnect_activate(), on_queryImportDlgOkBtn_clicked(), query_add(), query_import_dialog_create(), result_export(), send_callback(), and ws_save_file(). |
|
Shrinks the char string in the buffer by one character.
Definition at line 187 of file buf.c. References _a_buf::b_dat. Referenced by frm_check_fields(). |
|
append the string 's' to the buffer. The buffer is reallocated if necessary. buf = buf_strcat(buf, "Hello");
Definition at line 134 of file buf.c. References _a_buf::b_dat, _a_buf::b_len, buf_check(), buf_new(), and buf_terminate(). Referenced by cfg_get_default_wsname(), db_connect_dialog_reconnect(), frm_check_fields(), frm_save_file(), get_rcname(), my_DBform_to_url(), pg_DBform_to_url(), query_import_dialog_create(), query_save_dialog_create(), send_callback(), ws_save_file(), xp_DBform_to_url(), xp_DBget_field_value_attrib(), and xp_DBget_field_value_content(). |
|
Copy the string 's' into the buffer, replacing whatever's there. The buffer is reallocated if required. buf = buf_strcpy(buf, "Hello");
Definition at line 158 of file buf.c. References _a_buf::b_dat, _a_buf::b_len, buf_check(), buf_new(), and buf_terminate(). Referenced by cfg_get_default_wsname(), db_connect_dialog_reconnect(), frm_save_file(), my_DBform_to_url(), pg_DBform_to_url(), query_import_dialog_create(), query_save_dialog_create(), ws_save_file(), xp_DBget_field_value_attrib(), and xp_DBget_field_value_content(). |
|
Ensure that the last char in the buffer contains '\0'.
Definition at line 199 of file buf.c. References _a_buf::b_dat, and _a_buf::b_len. Referenced by buf_strcat(), and buf_strcpy(). |