@@ -100,15 +100,15 @@ class HdfsReadableFile::HdfsReadableFileImpl : public HdfsAnyFileImpl {
100
100
return Status::OK ();
101
101
}
102
102
103
- Status ReadAt (int64_t position, int32_t nbytes, int32_t * bytes_read, uint8_t * buffer) {
103
+ Status ReadAt (int64_t position, int64_t nbytes, int64_t * bytes_read, uint8_t * buffer) {
104
104
tSize ret = hdfsPread (fs_, file_, static_cast <tOffset>(position),
105
105
reinterpret_cast <void *>(buffer), nbytes);
106
106
RETURN_NOT_OK (CheckReadResult (ret));
107
107
*bytes_read = ret;
108
108
return Status::OK ();
109
109
}
110
110
111
- Status Read (int32_t nbytes, int32_t * bytes_read, uint8_t * buffer) {
111
+ Status Read (int64_t nbytes, int64_t * bytes_read, uint8_t * buffer) {
112
112
tSize ret = hdfsRead (fs_, file_, reinterpret_cast <void *>(buffer), nbytes);
113
113
RETURN_NOT_OK (CheckReadResult (ret));
114
114
*bytes_read = ret;
@@ -138,11 +138,11 @@ Status HdfsReadableFile::Close() {
138
138
}
139
139
140
140
Status HdfsReadableFile::ReadAt (
141
- int64_t position, int32_t nbytes, int32_t * bytes_read, uint8_t * buffer) {
141
+ int64_t position, int64_t nbytes, int64_t * bytes_read, uint8_t * buffer) {
142
142
return impl_->ReadAt (position, nbytes, bytes_read, buffer);
143
143
}
144
144
145
- Status HdfsReadableFile::Read (int32_t nbytes, int32_t * bytes_read, uint8_t * buffer) {
145
+ Status HdfsReadableFile::Read (int64_t nbytes, int64_t * bytes_read, uint8_t * buffer) {
146
146
return impl_->Read (nbytes, bytes_read, buffer);
147
147
}
148
148
@@ -177,7 +177,7 @@ class HdfsWriteableFile::HdfsWriteableFileImpl : public HdfsAnyFileImpl {
177
177
return Status::OK ();
178
178
}
179
179
180
- Status Write (const uint8_t * buffer, int32_t nbytes, int32_t * bytes_written) {
180
+ Status Write (const uint8_t * buffer, int64_t nbytes, int64_t * bytes_written) {
181
181
tSize ret = hdfsWrite (fs_, file_, reinterpret_cast <const void *>(buffer), nbytes);
182
182
CHECK_FAILURE (ret, " Write" );
183
183
*bytes_written = ret;
@@ -198,12 +198,12 @@ Status HdfsWriteableFile::Close() {
198
198
}
199
199
200
200
Status HdfsWriteableFile::Write (
201
- const uint8_t * buffer, int32_t nbytes, int32_t * bytes_read) {
201
+ const uint8_t * buffer, int64_t nbytes, int64_t * bytes_read) {
202
202
return impl_->Write (buffer, nbytes, bytes_read);
203
203
}
204
204
205
- Status HdfsWriteableFile::Write (const uint8_t * buffer, int32_t nbytes) {
206
- int32_t bytes_written_dummy = 0 ;
205
+ Status HdfsWriteableFile::Write (const uint8_t * buffer, int64_t nbytes) {
206
+ int64_t bytes_written_dummy = 0 ;
207
207
return Write (buffer, nbytes, &bytes_written_dummy);
208
208
}
209
209
0 commit comments