Commit b4ce557be5ec287b2f58c093439894bad98f4b88

Authored by Jay Berkenbilt
1 parent b4bdc42b

Fix error in QPDFSystemError.cc

Showing 1 changed file with 2 additions and 2 deletions
libqpdf/QPDFSystemError.cc
@@ -24,7 +24,7 @@ QPDFSystemError::createWhat(std::string const& description, @@ -24,7 +24,7 @@ QPDFSystemError::createWhat(std::string const& description,
24 // message is longer. strerror_s is a templated function that 24 // message is longer. strerror_s is a templated function that
25 // knows the size of buf and truncates. 25 // knows the size of buf and truncates.
26 char buf[94]; 26 char buf[94];
27 - if (strerror_s(buf, errno) != 0) 27 + if (strerror_s(buf, system_errno) != 0)
28 { 28 {
29 message = description + ": failed with an unknown error"; 29 message = description + ": failed with an unknown error";
30 } 30 }
@@ -33,7 +33,7 @@ QPDFSystemError::createWhat(std::string const& description, @@ -33,7 +33,7 @@ QPDFSystemError::createWhat(std::string const& description,
33 message = description + ": " + buf; 33 message = description + ": " + buf;
34 } 34 }
35 #else 35 #else
36 - message = description + ": " + strerror(errno); 36 + message = description + ": " + strerror(system_errno);
37 #endif 37 #endif
38 return message; 38 return message;
39 } 39 }