1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-09-29 03:17:53 -04:00
elinks/src/document/html/parse-meta-refresh.h
Witold Filipczyk 1f57e72212 [mozjs24] Allow build elinks with g++
SpiderMonkey was updated to mozjs24. If you want to build elinks
with ecmascript support, you must compile using g++ with -fpermissive .
There is a lot of warnings.
There are some memleaks in ecmascript code, especially related to JSAutoCompartment.
I don't know yet, where and how to free it.

Debian does not support mozjs24, so I'm going to gradually update SpiderMonkey version.
2020-10-05 20:14:55 +02:00

30 lines
780 B
C

#ifndef EL__DOCUMENT_HTML_PARSE_META_REFRESH_H
#define EL__DOCUMENT_HTML_PARSE_META_REFRESH_H
#ifdef __cplusplus
extern "C" {
#endif
/** Parses a \<meta http-equiv="refresh" content="..."> element.
*
* @param[in] content
* The value of the content attribute, with entities already expanded.
* @param[out] delay
* How many seconds to wait before refreshing.
* @param[out] url
* The URI to load when refreshing, or NULL to reload the same document.
* The caller must free the string with mem_free() unless it's NULL.
*
* @return
* 0 if successful, or negative on error.
* On error, *@a url is NULL. */
int html_parse_meta_refresh(const unsigned char *content,
unsigned long *delay,
unsigned char **url);
#ifdef __cplusplus
}
#endif
#endif