projects
/
m6w6
/
ext-http
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
| inline |
side by side
- sanitize stream filter
[m6w6/ext-http]
/
phpstr
/
phpstr.c
diff --git
a/phpstr/phpstr.c
b/phpstr/phpstr.c
index c0d9543f3d3e4a7e5b11b9d20b3aee68f3632c04..5a153dbcbc00b3bb6b56fae42ed69cd2cfd0918a 100644
(file)
--- a/
phpstr/phpstr.c
+++ b/
phpstr/phpstr.c
@@
-229,6
+229,12
@@
PHPSTR_API int phpstr_cmp(phpstr *left, phpstr *right)
}
}
+PHPSTR_API void phpstr_reset(phpstr *buf)
+{
+ buf->free += buf->used;
+ buf->used = 0;
+}
+
PHPSTR_API void phpstr_dtor(phpstr *buf)
{
STR_SET(buf->data, NULL);