projects
/
privoxy.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Let zalloc() use calloc() if it's available
[privoxy.git]
/
loaders.c
diff --git
a/loaders.c
b/loaders.c
index
1fdeabf
..
135b208
100644
(file)
--- a/
loaders.c
+++ b/
loaders.c
@@
-1,4
+1,4
@@
-const char loaders_rcs[] = "$Id: loaders.c,v 1.10
4 2016/05/22 12:43:07
fabiankeil Exp $";
+const char loaders_rcs[] = "$Id: loaders.c,v 1.10
5 2016/05/25 10:50:55
fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/loaders.c,v $
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/loaders.c,v $
@@
-74,7
+74,9
@@
const char loaders_h_rcs[] = LOADERS_H_VERSION;
static struct file_list *current_trustfile = NULL;
#endif /* def FEATURE_TRUST */
static struct file_list *current_trustfile = NULL;
#endif /* def FEATURE_TRUST */
+#ifndef FUZZ
static int load_one_re_filterfile(struct client_state *csp, int fileid);
static int load_one_re_filterfile(struct client_state *csp, int fileid);
+#endif
static struct file_list *current_re_filterfile[MAX_AF_FILES] = {
NULL, NULL, NULL, NULL, NULL,
static struct file_list *current_re_filterfile[MAX_AF_FILES] = {
NULL, NULL, NULL, NULL, NULL,
@@
-361,6
+363,7
@@
jb_err simple_read_line(FILE *fp, char **dest, int *newline)
for (;;)
{
ch = getc(fp);
for (;;)
{
ch = getc(fp);
+
if (ch == EOF)
{
if (len > 0)
if (ch == EOF)
{
if (len > 0)
@@
-417,6
+420,7
@@
jb_err simple_read_line(FILE *fp, char **dest, int *newline)
}
else if (ch == 0)
{
}
else if (ch == 0)
{
+ /* XXX: Why do we allow this anyway? */
*p = '\0';
*dest = buf;
return JB_ERR_OK;
*p = '\0';
*dest = buf;
return JB_ERR_OK;