[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always
From: |
Paul Eggert |
Subject: |
[Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB |
Date: |
Tue, 12 Nov 2024 14:15:45 -0500 (EST) |
Follow-up Comment #13, bug #66399 (group octave):
> Should we also avoid to use `fseek` with pipes?
C code should avoid fseek; always use fseeko. Although fseek should work with
small-enough offsets why ask for trouble?
If you use fseeko on a pipe, it should either work (if it's a small seek that
stays within the I/O buffer) or fail with errno=ESPIPE; it can also fail for
other reasons.
I don't know about std::fseeko, as I don't use C++. However, Gnulib does
attempt to make its fseeko replacement visible to C++ using the usual
namespace rules. Perhaps this is relevant to your problem, but you'll need a
C++ expert to diagnose it.
I see that you do appear to be trying to work around the issue with
octave_fseeko_wrapper, which I don't fully understand. If you have that, why
use std::fseek in libinterp/corefcn/gl2ps-print.cc? Shouldn't that code use
octave_lseeko_wrapper instead?
Bruno Haible knows C++ and MS-Windows (I know neither), and I hope he'll reply
again on bug-gnulib and clear up some of the confusion here.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?66399>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
signature.asc
Description: PGP signature
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11, (continued)
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11, Dmitri A. Sergatskov, 2024/11/06
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11, Nicholas Jankowski, 2024/11/06
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11, Nicholas Jankowski, 2024/11/06
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Nicholas Jankowski, 2024/11/06
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/11
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/11
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Paul Eggert, 2024/11/11
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/12
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Paul Eggert, 2024/11/12
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Paul Eggert, 2024/11/12
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB,
Paul Eggert <=
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/13
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/14
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Dmitri A. Sergatskov, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Dmitri A. Sergatskov, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Dmitri A. Sergatskov, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Markus Mützel, 2024/11/15
- [Octave-bug-tracker] [bug #66399] fseek and ftell functions don't always work correctly on Win11 with filesizes >2GB, Rik, 2024/11/25