haml--haml/ext/haml/hescape.h

21 lines
430 B
C
Raw Normal View History

2016-08-13 03:57:40 +00:00
#ifndef HESCAPE_H
#define HESCAPE_H
#include <sys/types.h>
/*
* Replace characters according to the following rules.
* Note that this function can handle only ASCII-compatible string.
*
* " => &quot;
* & => &amp;
* ' => &#39;
* < => &lt;
* > => &gt;
*
* @return size of dest. If it's larger than len, dest is required to be freed.
*/
2016-08-13 04:16:14 +00:00
extern size_t hesc_escape_html(char **dest, const char *src, size_t size);
2016-08-13 03:57:40 +00:00
#endif