projects
/
jansson.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
bf32f6c
)
Emphasize the constness of the return value of json_string_value()
author
Petri Lehtinen
<petri@digip.org>
Mon, 20 Dec 2010 19:08:04 +0000
(21:08 +0200)
committer
Petri Lehtinen
<petri@digip.org>
Mon, 20 Dec 2010 19:08:11 +0000
(21:08 +0200)
Closes GH-7.
doc/apiref.rst
patch
|
blob
|
history
diff --git
a/doc/apiref.rst
b/doc/apiref.rst
index
e37cb8c
..
dcc0cbf
100644
(file)
--- a/
doc/apiref.rst
+++ b/
doc/apiref.rst
@@
-306,6
+306,10
@@
U+10FFFF are allowed.
Returns the associated value of *string* as a null terminated UTF-8
encoded string, or *NULL* if *string* is not a JSON string.
Returns the associated value of *string* as a null terminated UTF-8
encoded string, or *NULL* if *string* is not a JSON string.
+ The retuned value is read-only and must not be modified or freed by
+ the user. It is valid as long as *string* exists, i.e. as long as
+ its reference count has not dropped to zero.
+
.. function:: int json_string_set(const json_t *string, const char *value)
Sets the associated value of *string* to *value*. *value* must be a
.. function:: int json_string_set(const json_t *string, const char *value)
Sets the associated value of *string* to *value*. *value* must be a