Re: SOCK5 crash+fix
Gisle Vanem <[email protected]>
| Newsgroups | gmane.comp.web.lynx.devel |
|---|---|
| Message-ID | <[email protected]> |
>> HTSprintf0 expects to have the address of a pointer in which it
>> can return a pointer to newly-allocated memory.
>
> 'HTSprintf0(NULL,..)' looks okay to me, but crashes
> on some condition anyway. Some Runtime-Checks that gets
> confused (?).
I think I found the cause of it:
--- orig/WWW/Library/Implementation/HTString.c 2021-06-09 22:16:06
+++ WWW/Library/Implementation/HTString.c 2022-03-11 13:48:17
char *dst_ptr = *pstr;
const char *format = fmt;
- char *dst_ptr = *pstr; // line 680
+ char *dst_ptr = pstr ? *pstr : NULL;