On Tue, May 14, 2024 at 6:58 AM David Rowley <dgrowle...@gmail.com> wrote: > On Fri, 3 May 2024 at 16:03, David Rowley <dgrowle...@gmail.com> wrote: > > I'm trying to figure out why BufFileSize() Asserts that file->fileset > > isn't NULL, per 1a990b207. > > I was hoping to get some feedback here.
Notice that comments above BufFileSize() say "Return the current fileset based BufFile size". There are numerous identical assertions at the start of several other functions within the same file. I'm not sure what it would take for this function to support OpenTemporaryFile()-based BufFiles -- possibly not very much at all. I assume that that's what you're actually interested in doing here (you didn't say). If it is, you'll need to update the function's contract -- just removing the assertion isn't enough. -- Peter Geoghegan