Thomas Dickey wrote:

MinGW in that area is just plain broken.

MingW *can* use >4 GB 'st_size' from stat() just fine in other
programs. E.g. curl + Wget.

You probably can't get that with 32-bit MSVC.

MSVC v16 (32-bit too). I think the problem is in StrAllocVsprintf()
(via HTSprintf0). It doesn't understand formats such as 'I64d'.
But the code around this so messy I don't know what to do about it.

In HTFile.c I have asserted that 'off_t' really is 64-bits.
So in:

static char *FormatSize(char **bufp,
                        char *start,
                        off_t entry)
{
    char fmt[512];

    if (*start) {
        sprintf(fmt, "%%%.*s" PRI_off_t, (int) sizeof(fmt) - 3, start);

        HTSprintf0(bufp, fmt, entry);
    } else {
        sprintf(fmt, "%" PRI_off_t, CAST_off_t (entry));

On Win32, what should 'fmt' become for HTSprintf0() to do it right?
Since "%I64d" is not supported, should PRI_OFF_t be forced to "lld"
on Windows too?

--
--gv

_______________________________________________
Lynx-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/lynx-dev

Reply via email to