summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c73852f)
raw | patch | inline | side by side (parent: c73852f)
author | Sebastian Harl <sh@tokkee.org> | |
Sun, 22 Jun 2014 15:28:04 +0000 (17:28 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Sun, 22 Jun 2014 15:28:04 +0000 (17:28 +0200) |
src/core/data.c | patch | blob | history | |
src/include/core/data.h | patch | blob | history |
diff --git a/src/core/data.c b/src/core/data.c
index 0e8cfcb744092636be1da4398e95334d945b79ab..dc2d0ae8afde4dbb741bc2525444fddad05ed0a8 100644 (file)
--- a/src/core/data.c
+++ b/src/core/data.c
} /* sdb_data_cmp */
size_t
-sdb_data_strlen(sdb_data_t *datum)
+sdb_data_strlen(const sdb_data_t *datum)
{
if (! datum)
return 0;
} /* sdb_data_strlen */
int
-sdb_data_format(sdb_data_t *datum, char *buf, size_t buflen, int quoted)
+sdb_data_format(const sdb_data_t *datum, char *buf, size_t buflen, int quoted)
{
char tmp[sdb_data_strlen(datum) + 1];
char *data = NULL;
index bd102669ce2d2873a2c2f0ef3b7bb64278483d13..879af9087db92d7346fee2109326df55eaf25dfc 100644 (file)
--- a/src/include/core/data.h
+++ b/src/include/core/data.h
* account.
*/
size_t
-sdb_data_strlen(sdb_data_t *datum);
+sdb_data_strlen(const sdb_data_t *datum);
enum {
SDB_UNQUOTED = 0,
* - a negative value else
*/
int
-sdb_data_format(sdb_data_t *datum, char *buf, size_t buflen, int quoted);
+sdb_data_format(const sdb_data_t *datum, char *buf, size_t buflen, int quoted);
#ifdef __cplusplus
} /* extern "C" */