diff --git a/src/main.cxx b/src/main.cxx
index 625954b..d84e70b 100644
--- a/src/main.cxx
+++ b/src/main.cxx
@@ -315,7 +315,7 @@ void rotate_log(std::string filename)
{
const int n = 5; // rename existing log files to keep up to 5 old versions
ostringstream oldfn, newfn;
- ostringstream::streampos p;
+ std::streampos p;
oldfn << filename << '.';
newfn << filename << '.';