mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Added a typecast in cUnbufferedFile::Write() to avoid an error message when compiling on 64 bit systems
This commit is contained in:
parent
970622ccf2
commit
0c5374ce7d
2
HISTORY
2
HISTORY
@ -5922,3 +5922,5 @@ Video Disk Recorder Revision History
|
|||||||
implements this change in the driver.
|
implements this change in the driver.
|
||||||
The the patch av7110_v4ldvb_api5_audiobuf_test_1.diff mentioned in version 1.7.2
|
The the patch av7110_v4ldvb_api5_audiobuf_test_1.diff mentioned in version 1.7.2
|
||||||
is no longer necessary.
|
is no longer necessary.
|
||||||
|
- Added a typecast in cUnbufferedFile::Write() to avoid an error message when
|
||||||
|
compiling on 64 bit systems.
|
||||||
|
4
tools.c
4
tools.c
@ -4,7 +4,7 @@
|
|||||||
* See the main source file 'vdr.c' for copyright information and
|
* See the main source file 'vdr.c' for copyright information and
|
||||||
* how to reach the author.
|
* how to reach the author.
|
||||||
*
|
*
|
||||||
* $Id: tools.c 2.1 2009/01/05 13:04:10 kls Exp $
|
* $Id: tools.c 2.2 2009/01/16 14:29:08 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "tools.h"
|
#include "tools.h"
|
||||||
@ -1608,7 +1608,7 @@ ssize_t cUnbufferedFile::Write(const void *Data, size_t Size)
|
|||||||
// kind of write gathering enabled), but the syncs cause (io) load..
|
// kind of write gathering enabled), but the syncs cause (io) load..
|
||||||
// Uncomment the next line if you think you need them.
|
// Uncomment the next line if you think you need them.
|
||||||
//fdatasync(fd);
|
//fdatasync(fd);
|
||||||
off_t headdrop = min(curpos - totwritten, off_t(totwritten * 2));
|
off_t headdrop = min(off_t(curpos - totwritten), off_t(totwritten * 2));
|
||||||
posix_fadvise(fd, curpos - totwritten - headdrop, totwritten + headdrop, POSIX_FADV_DONTNEED);
|
posix_fadvise(fd, curpos - totwritten - headdrop, totwritten + headdrop, POSIX_FADV_DONTNEED);
|
||||||
totwritten = 0;
|
totwritten = 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user