Dillo v3.1.1-46-g8a360e32
Loading...
Searching...
No Matches
dpiutil.h
Go to the documentation of this file.
1/*
2 * File: dpiutil.h
3 *
4 * Copyright 2004-2005 Jorge Arellano Cid <jcid@dillo.org>
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 */
12
13/*
14 * This file contains common functions used by dpi programs.
15 * (i.e. a convenience library).
16 */
17
18#ifndef __DPIUTIL_H__
19#define __DPIUTIL_H__
20
21#include <stdio.h>
22#include "d_size.h"
23#include "../dlib/dlib.h"
24
25
26#ifdef __cplusplus
27extern "C" {
28#endif /* __cplusplus */
29
30
31/*
32 * Escape URI characters in 'esc_set' as %XX sequences.
33 * Return value: New escaped string.
34 */
35char *Escape_uri_str(const char *str, const char *p_esc_set);
36
37/*
38 * Unescape %XX sequences in a string.
39 * Return value: a new unescaped string
40 */
41char *Unescape_uri_str(const char *str);
42
43/*
44 * Escape unsafe characters as html entities.
45 * Return value: New escaped string.
46 */
47char *Escape_html_str(const char *str);
48
49/*
50 * Unescape a few HTML entities (inverse of Escape_html_str)
51 * Return value: New unescaped string.
52 */
53char *Unescape_html_str(const char *str);
54
55/*
56 * Filter an SMTP hack with a FTP URI
57 */
58char *Filter_smtp_hack(char *url);
59
60
61#ifdef __cplusplus
62}
63#endif /* __cplusplus */
64
65#endif /* __DPIUTIL_H__ */
66
char * Escape_html_str(const char *str)
Definition dpiutil.c:93
char * Unescape_uri_str(const char *str)
Definition dpiutil.c:64
char * Filter_smtp_hack(char *url)
Definition dpiutil.c:148
char * Unescape_html_str(const char *str)
Definition dpiutil.c:115
char * Escape_uri_str(const char *str, const char *p_esc_set)
Definition dpiutil.c:36