projects
/
privoxy.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
4eaf88d
)
get_content_length(): Replace an assertion with a compile-time check
author
Fabian Keil
<fk@fabiankeil.de>
Thu, 8 Jun 2017 13:13:26 +0000
(13:13 +0000)
committer
Fabian Keil
<fk@fabiankeil.de>
Thu, 8 Jun 2017 13:13:26 +0000
(13:13 +0000)
parsers.c
patch
|
blob
|
history
diff --git
a/parsers.c
b/parsers.c
index
57e5cde
..
011641d
100644
(file)
--- a/
parsers.c
+++ b/
parsers.c
@@
-1,4
+1,4
@@
-const char parsers_rcs[] = "$Id: parsers.c,v 1.31
0 2016/12/09 09:13:1
9 fabiankeil Exp $";
+const char parsers_rcs[] = "$Id: parsers.c,v 1.31
1 2016/12/24 16:00:4
9 fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/parsers.c,v $
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/parsers.c,v $
@@
-1816,7
+1816,9
@@
static jb_err client_keep_alive(struct client_state *csp, char **header)
static jb_err get_content_length(const char *header_value, unsigned long long *length)
{
#ifdef _WIN32
static jb_err get_content_length(const char *header_value, unsigned long long *length)
{
#ifdef _WIN32
- assert(sizeof(unsigned long long) > 4);
+#if SIZEOF_LONG_LONG < 8
+#error sizeof(unsigned long long) too small
+#endif
if (1 != sscanf(header_value, "%I64u", length))
#else
if (1 != sscanf(header_value, "%llu", length))
if (1 != sscanf(header_value, "%I64u", length))
#else
if (1 != sscanf(header_value, "%llu", length))