Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-ports-kde
Path: blob/main/benchmarks/bonnie++/files/patch-zcav__io.cpp
16461 views
1
--- zcav_io.cpp.orig 2012-11-23 07:34:43 UTC
2
+++ zcav_io.cpp
3
@@ -83,7 +83,6 @@ int ZcavRead::Read(int max_loops, int ma
4
for(int loops = 0; !exiting && loops < max_loops; loops++)
5
{
6
int i = 0;
7
-#ifdef _LARGEFILE64_SOURCE
8
if(start_offset)
9
{
10
OFF_TYPE real_offset = OFF_TYPE(start_offset) * OFF_TYPE(m_block_size) * OFF_TYPE(1<<20);
11
@@ -96,7 +95,6 @@ int ZcavRead::Read(int max_loops, int ma
12
i = start_offset;
13
}
14
else
15
-#endif
16
if(lseek(m_fd, 0, SEEK_SET))
17
{
18
fprintf(stderr, "Can't lseek().\n");
19
@@ -224,14 +222,12 @@ ssize_t ZcavRead::access_all(int count)
20
// Read/write a block of data
21
double ZcavRead::access_data(int skip)
22
{
23
-#ifdef _LARGEFILE64_SOURCE
24
if(skip)
25
{
26
OFF_TYPE real_offset = OFF_TYPE(skip) * OFF_TYPE(m_block_size) * OFF_TYPE(1<<20);
27
if(file_lseek(m_fd, real_offset, SEEK_CUR) == OFF_TYPE(-1))
28
return -1.0;
29
}
30
-#endif
31
32
m_dur.start();
33
for(int i = 0; i < m_block_size; i+= m_chunk_size)
34
35