commit fd75f172c891d725616f845d1da22a8f2f9dd930
parent 4ffab4e1de2e630c8ecbd5a6805c6a228e78cc99
Author: ukai <ukai>
Date: Mon, 14 Apr 2003 03:29:37 +0000
[w3m-dev 03875] Re: SSL & compressed stream
* file.c (loadGeneralFile): check t_buf != NULL
* url.c (openURL): don't initialize URLFile here
(init_stream): 0 clear URLFile
From: Fumitoshi UKAI <ukai@debian.or.jp>
Diffstat:
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/ChangeLog b/ChangeLog
@@ -1,5 +1,12 @@
2003-04-14 Fumitoshi UKAI <ukai@debian.or.jp>
+ * [w3m-dev 03875] Re: SSL & compressed stream
+ * file.c (loadGeneralFile): check t_buf != NULL
+ * url.c (openURL): don't initialize URLFile here
+ (init_stream): 0 clear URLFile
+
+2003-04-14 Fumitoshi UKAI <ukai@debian.or.jp>
+
* [w3m-dev 03873] SSL & compressed stream
* file.c (loadGeneralFile): always update ssl_certificate
* url.c (openURL): initialize URLFile
diff --git a/file.c b/file.c
@@ -2043,7 +2043,8 @@ loadGeneralFile(char *path, ParsedURL *volatile current, char *referer,
t_buf->bufferprop |= BP_FRAME;
}
#ifdef USE_SSL
- t_buf->ssl_certificate = f.ssl_certificate;
+ if (t_buf)
+ t_buf->ssl_certificate = f.ssl_certificate;
#endif
frame_source = flag & RG_FRAME_SRC;
b = loadSomething(&f, pu.real_file ? pu.real_file : pu.file, proc, t_buf);
diff --git a/url.c b/url.c
@@ -1437,6 +1437,7 @@ HTTPrequest(ParsedURL *pu, ParsedURL *current, HRequest *hr, TextList *extra)
void
init_stream(URLFile *uf, int scheme, InputStream stream)
{
+ memset(uf, 0, sizeof(URLFile));
uf->stream = stream;
uf->scheme = scheme;
uf->encoding = ENC_7BIT;
@@ -1497,7 +1498,6 @@ openURL(char *url, ParsedURL *pu, ParsedURL *current,
}
}
- memset(&uf, 0, sizeof uf);
uf.scheme = pu->scheme;
uf.url = parsedURL2Str(pu)->ptr;
pu->is_nocache = (option->flag & RG_NOCACHE);