mirror of
https://github.com/aria2/aria2.git
synced 2026-04-13 00:09:32 +00:00
2008-08-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed error handling of lseek. * src/AbstractDiskWriter.cc
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2008-08-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||
|
||||
Fixed error handling of lseek.
|
||||
* src/AbstractDiskWriter.cc
|
||||
|
||||
2008-08-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||
|
||||
Removed "(1.x/2.x)" from TEXT_LOAD_COOKIES since aria2 can load Firefox3
|
||||
|
||||
@@ -124,7 +124,7 @@ ssize_t AbstractDiskWriter::readDataInternal(unsigned char* data, size_t len)
|
||||
|
||||
void AbstractDiskWriter::seek(off_t offset)
|
||||
{
|
||||
if(offset != lseek(fd, offset, SEEK_SET)) {
|
||||
if(lseek(fd, offset, SEEK_SET) == (off_t)-1) {
|
||||
throw DlAbortEx
|
||||
(StringFormat(EX_FILE_SEEK, filename.c_str(), strerror(errno)).str());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user