search for: getfiletype

Displaying 15 results from an estimated 15 matches for "getfiletype".

2015 Dec 10
5
Windows file buffering
...t? For example, <http://git.xiph.org/?p=flac.git;a=commitdiff;h=d66f6754bf94bc8ba23d3579d0b5650cd380c9f0> ? Because setvbuf() should definitely change libFLAC behaviour regardless of files/pipes/etc. The attached patch *should* resolve the issue. libFLAC will call setvbuf(file, ...) only if GetFileType(...file...) == FILE_TYPE_DISK. -------------- next part -------------- A non-text attachment was scrubbed... Name: buffering.patch Type: application/octet-stream Size: 615 bytes Desc: not available Url : http://lists.xiph.org/pipermail/flac-dev/attachments/20151210/c3bffdd5/attachment.obj
2001 May 16
1
wine-20010510 fails to run?
...4 ret=00469920 08067f18:Call kernel32.GetStdHandle(fffffff5) ret=0046992c 08067f18:Ret kernel32.GetStdHandle() retval=00000008 ret=0046992c 08067f18:Call kernel32.GetStdHandle(fffffff4) ret=00469938 08067f18:Ret kernel32.GetStdHandle() retval=0000000c ret=00469938 08067f18:Call kernel32.GetFileType(00000004) ret=00469e55 08067f18:Ret kernel32.GetFileType() retval=00000002 ret=00469e55 08067f18:Call kernel32.GetFileType(00000008) ret=00469e55 08067f18:Ret kernel32.GetFileType() retval=00000002 ret=00469e55 08067f18:Call kernel32.GetFileType(0000000c) ret=00469e55 08067f18:Ret kern...
2008 Dec 18
5
EverQuest - worked once, but no more
...05bc285 > 0009:Ret KERNEL32.SetLastError() retval=00000002 ret=005bc285 > 0009:Call KERNEL32.CreateFileA(005eed7c "dbg.txt",40000000,00000003,0032e784,00000004,00000080,00000000) ret=005bb32b > 0009:Ret KERNEL32.CreateFileA() retval=00000058 ret=005bb32b > 0009:Call KERNEL32.GetFileType(00000058) ret=005bb338 > 0009:Ret KERNEL32.GetFileType() retval=00000001 ret=005bb338 > 0009:Call ntdll.RtlAllocateHeap(00bf0000,00000000,00001000) ret=005b6319 > 0009:Ret ntdll.RtlAllocateHeap() retval=00bf89b8 ret=005b6319 > 0009:Call KERNEL32.SetFilePointer(00000058,00000000,000000...
2016 Feb 09
2
Compilation failure using mingw-w64 and gcc-5.3.0
...ILE_ATTRIBUTE_NORMAL, NULL); ^ decode.c:271:14: error: 'INVALID_HANDLE_VALUE' undeclared (first use in this function) if(fh != INVALID_HANDLE_VALUE) { ^ decode.c:272:9: warning: implicit declaration of function 'GetFileType' [-Wimplicit-function-declaration] if(GetFileType(fh) == FILE_TYPE_DISK) { ^ decode.c:272:6: warning: nested extern declaration of 'GetFileType' [-Wnested-externs] if(GetFileType(fh) == FILE_TYPE_DISK) { ^ decode.c:272:28: error: 'FILE_TYPE_DISK' undec...
2016 Feb 08
2
Compilation failure using mingw-w64 and gcc-5.3.0
Hello, Upon compiling the flac tree today, after many successful compilations over the last few weeks, a new error is appearing before compilation bails out. This is a cross-compilation using gcc-5.3.0 running on GNU/Linux, with the objects being built for a mingw-w64-x86_64 host. Among other things, the compiler is looking for windows_unicode_filenames.h but it isn't there. Also, I'm
2014 Sep 26
4
Patch to add buffering to decoding too
...#ifdef _WIN32 + if(strcmp(outfilename, "-") && d->total_samples > 0) { + HANDLE fh = CreateFile_utf8(outfilename, GENERIC_READ|GENERIC_WRITE, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); + if(fh != INVALID_HANDLE_VALUE) { + if (GetFileType(fh) == FILE_TYPE_DISK) { + LARGE_INTEGER size; + size.QuadPart = d->total_samples * d->channels * ((d->bps+7)/8) + 512; + if(d->foreign_metadata) { + size_t i; + for(i = d->format==FORMAT_RF64?2:1; i < d->foreign_metadata->num_blocks; i++) { + if(...
2014 Sep 27
0
Patch to add buffering to decoding too
...red) { + FLAC__off_t written_size = ftello(d->fout); + if(written_size > 0) { + HANDLE fh = CreateFile_utf8(d->outfilename, GENERIC_READ|GENERIC_WRITE, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); + if(fh != INVALID_HANDLE_VALUE) { + if(GetFileType(fh) == FILE_TYPE_DISK) { + LARGE_INTEGER size; + size.QuadPart = written_size; + if(SetFilePointerEx(fh, size, NULL, FILE_CURRENT)) /* correct the file size */ + SetEndOfFile(fh); + } + CloseHandle(fh); + } + } + } +#endif fclose(d->fout); if(error_occur...
2015 Dec 10
0
Windows file buffering
...p=flac.git;a=commitdiff;h=d66f6754bf94bc8ba23d3579d0b5650cd380c9f0> > ? > Because setvbuf() should definitely change libFLAC behaviour > regardless of files/pipes/etc. > > > The attached patch *should* resolve the issue. libFLAC will call > setvbuf(file, ...) > only if GetFileType(...file...) == FILE_TYPE_DISK. I probably don't know enough about the intricates of Win32, but why not prefer this for clarity: diff --git a/src/libFLAC/stream_encoder.c b/src/libFLAC/stream_encoder.c index 203a271..0394c26 100644 --- a/src/libFLAC/stream_encoder.c +++ b/src/libFLAC/stream_en...
2015 Dec 10
0
Windows file buffering
...> Maybe you mean some other commit? For example, > <http://git.xiph.org/?p=flac.git;a=commitdiff;h=d66f6754bf94bc8ba23d3579d0b5650cd380c9f0> ? Yes, that is exactly what i meant. > > The attached patch *should* resolve the issue. libFLAC will call setvbuf(file, ...) > only if GetFileType(...file...) == FILE_TYPE_DISK. That patch looks correct. That said, i'm not sure why there's setvbuf() in the first place. I mean, the code to de-fragment the output file already exists (the aforementioned d66f675), so why buffering? Was it proven empirically that buffering is required? Or...
2015 Dec 10
2
Windows file buffering
lvqcl, Would you be able to have alook at this one? I think its Windows related: https://sourceforge.net/p/flac/feature-requests/114/ Erik -- ---------------------------------------------------------------------- Erik de Castro Lopo http://www.mega-nerd.com/
2014 Sep 26
0
Patch to add buffering to decoding too
...#ifdef _WIN32 + if(strcmp(outfilename, "-") && d->total_samples > 0) { + HANDLE fh = CreateFile_utf8(outfilename, GENERIC_READ|GENERIC_WRITE, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); + if(fh != INVALID_HANDLE_VALUE) { + if (GetFileType(fh) == FILE_TYPE_DISK) { + LARGE_INTEGER size, pos; + + size.QuadPart = d->total_samples * d->channels * ((d->bps+7)/8) + 512; + if(d->foreign_metadata) { + size_t i; + for(i = d->format==FORMAT_RF64?2:1; i < d->foreign_metadata->num_blocks; i++) { +...
2014 Sep 26
3
Patch to add buffering to decoding too
Can you please wrap the setvbuf in _WIN32 IFDEFs too? Currently memory usage of FLAC decoding is about 1MB, so this patch is increasing memory usage tenfold, also for platforms that do not need this. It is a non-problem on my system anyway. Op 26-09-14 om 10:36 schreef Janne Hyv?rinen: > I made some changes to the previous patch. I don't know why I > originally didn't put the
2014 Sep 25
2
Patch to add buffering to decoding too
Decoding flac files is also prone to producing fragmented files. NTFS has the ability to completely avoid fragmentation if it is told the file size before hand, but that would require using special Windows-only functions. Increasing the write buffer from the default 512 bytes to 10 MB already reduces the problem tremendously. -------------- next part -------------- diff --git
2004 May 28
2
Problem with ADO connection
Hi, First a big Thank You to the wine developers. Your efforts are greatly appreciated and have allowed me to move users to Linux that I could never have moved otherwise. I am currently setting up desktops for 7 end users, but doing so requires that I get a particular application (The Electronic Manual) which is a parts catalog for the restaurant equipment service industry. The application
2014 Feb 07
0
Wine release 1.7.12
...e handles returned by GetStdHandle function. msvcm90: Share the source code with msvcm80. msvcm90: Don't forward to msvcm80. msvcp70: Share the source code with msvcp90. msvcp70: Don't forward bad_alloc implementation to msvcrt. kernel32: Handle STD_*_HANDLE in GetFileType. Sebastian Lackner (9): winex11: Catch invalid values from broken QX11EmbedContainer implementations. ntdll: Throw STATUS_RESOURCE_NOT_OWNED when it's impossible to acquire/release the SRWLock. ntdll: Implement RtlTryAcquireSRWLockShared/Exclusive commands. kernel32: Fo...