summaryrefslogtreecommitdiff
path: root/src/SFML/System/FileInputStream.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/SFML/System/FileInputStream.cpp')
-rw-r--r--src/SFML/System/FileInputStream.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/SFML/System/FileInputStream.cpp b/src/SFML/System/FileInputStream.cpp
index 82f4d72..09af98d 100644
--- a/src/SFML/System/FileInputStream.cpp
+++ b/src/SFML/System/FileInputStream.cpp
@@ -1,7 +1,7 @@
////////////////////////////////////////////////////////////
//
// SFML - Simple and Fast Multimedia Library
-// Copyright (C) 2007-2015 Laurent Gomila (laurent@sfml-dev.org)
+// Copyright (C) 2007-2016 Laurent Gomila (laurent@sfml-dev.org)
//
// This software is provided 'as-is', without any express or implied warranty.
// In no event will the authors be held liable for any damages arising from the use of this software.
@@ -95,7 +95,9 @@ Int64 FileInputStream::seek(Int64 position)
#else
if (m_file)
{
- std::fseek(m_file, static_cast<std::size_t>(position), SEEK_SET);
+ if (std::fseek(m_file, static_cast<std::size_t>(position), SEEK_SET))
+ return -1;
+
return tell();
}
else