Re: [fluid-dev] About Supporting 2GiB+ Soundfonts on Windows

2020-03-17 Thread Dan Eble
On Mar 17, 2020, at 04:44, Tom M. via fluid-dev wrote: > latter doesn't really make sense in practice, because long long is an > intrinsic type guaranteed to be at least 64 bits wide. And because > long long must be available, int64_t will also be available.) That describes int_least64_t. In an

Re: [fluid-dev] About Supporting 2GiB+ Soundfonts on Windows

2020-03-17 Thread Ceresa Jean-Jacques
>Based on Reinhold's thought, the idea would be to use something like #if defined(_MSVC_VER < VisualStudio2015) typedef __int64 fluid_long_long_t; // even on 32bit windows #else typedef long long fluid_long_long_t; #endif >Should it really be that simple or am I missing smth.?   You are not mis

Re: [fluid-dev] About Supporting 2GiB+ Soundfonts on Windows

2020-03-17 Thread Tom M. via fluid-dev
There is no guarantee that sf->sffd is a FILE* . Again, this is exposed via our API. sf->sffd is a void*, which could be some user defined handle, which, when passing to fseek(), would result in an access violation and in a horrible, possibly-hard-to-reproduce crash of the entire application. I

Re: [fluid-dev] About Supporting 2GiB+ Soundfonts on Windows

2020-03-17 Thread Carlo Bramini via fluid-dev
Hello, although it is true that you cannot handle files larger than 2GB with current code, there is one thing that's strange in that bug report. If you really have not large file support, the first function to fail should be fseek() and not ftell(), so the first message you should read in the co

Re: [fluid-dev] About Supporting 2GiB+ Soundfonts on Windows

2020-03-17 Thread Tom M. via fluid-dev
> If you decided to require C99, I would think you would want to use int64_t > and its relatives for portability. I actually had "long long" in mind, because int64_t would require fluidsynth's header to include stdint.h, and whenever possible I would like to avoid polluting our header with any C