diff options
Diffstat (limited to 'fastos/src')
-rw-r--r-- | fastos/src/tests/typetest.cpp | 1 | ||||
-rw-r--r-- | fastos/src/vespa/fastos/file.cpp | 7 | ||||
-rw-r--r-- | fastos/src/vespa/fastos/file.h | 11 | ||||
-rw-r--r-- | fastos/src/vespa/fastos/linux_file.cpp | 1 | ||||
-rw-r--r-- | fastos/src/vespa/fastos/linux_file.h | 3 | ||||
-rw-r--r-- | fastos/src/vespa/fastos/unix_file.cpp | 4 |
6 files changed, 3 insertions, 24 deletions
diff --git a/fastos/src/tests/typetest.cpp b/fastos/src/tests/typetest.cpp index 51bda7e5dbc..209af305501 100644 --- a/fastos/src/tests/typetest.cpp +++ b/fastos/src/tests/typetest.cpp @@ -2,6 +2,7 @@ #include "tests.h" #include <vespa/fastos/file.h> +#include <vespa/fastos/time.h> #include <vespa/fastos/serversocket.h> #include <cstdlib> diff --git a/fastos/src/vespa/fastos/file.cpp b/fastos/src/vespa/fastos/file.cpp index b7da72db420..5c4d7ce9445 100644 --- a/fastos/src/vespa/fastos/file.cpp +++ b/fastos/src/vespa/fastos/file.cpp @@ -462,13 +462,6 @@ FastOS_FileInterface::OpenWriteOnly(const char *filename) return Open(FASTOS_FILE_OPEN_WRITE, filename); } - -bool -FastOS_FileInterface::OpenStdin() -{ - return Open(FASTOS_FILE_OPEN_STDIN); -} - FastOS_File::Error FastOS_FileInterface::GetLastError() { diff --git a/fastos/src/vespa/fastos/file.h b/fastos/src/vespa/fastos/file.h index 43e10fcd120..a9be683d395 100644 --- a/fastos/src/vespa/fastos/file.h +++ b/fastos/src/vespa/fastos/file.h @@ -10,12 +10,7 @@ #pragma once -#include <vespa/fastos/types.h> -#include <vespa/fastos/mutex.h> -#include <vespa/fastos/time.h> - -#include <vespa/fastos/thread.h> - +#include "types.h" #include <string> const int FASTOS_FILE_OPEN_READ = (1<<0); @@ -23,12 +18,10 @@ const int FASTOS_FILE_OPEN_WRITE = (1<<1); const int FASTOS_FILE_OPEN_EXISTING = (1<<2); const int FASTOS_FILE_OPEN_CREATE = (1<<3); const int FASTOS_FILE_OPEN_TRUNCATE = (1<<4); -const int FASTOS_FILE_OPEN_STDIN = (1<<5); // Use 2 bits here const int FASTOS_FILE_OPEN_STDOUT = (2<<5); const int FASTOS_FILE_OPEN_STDERR = (3<<5); const int FASTOS_FILE_OPEN_STDFLAGS = (3<<5); const int FASTOS_FILE_OPEN_DIRECTIO = (1<<7); -const int FASTOS_FILE_OPEN_SHAREREAD = (1<<8); const int FASTOS_FILE_OPEN_SYNCWRITES = (1<<9); // synchronous writes /** @@ -329,8 +322,6 @@ public: */ bool OpenWriteOnly(const char *filename=nullptr); - bool OpenStdin(); - /** * Close the file. The call will successfully do nothing if the file * already is closed. diff --git a/fastos/src/vespa/fastos/linux_file.cpp b/fastos/src/vespa/fastos/linux_file.cpp index 08dc78585ec..6af3bd207a0 100644 --- a/fastos/src/vespa/fastos/linux_file.cpp +++ b/fastos/src/vespa/fastos/linux_file.cpp @@ -14,7 +14,6 @@ const size_t FastOS_Linux_File::_directIOFileAlign = 4096; const size_t FastOS_Linux_File::_directIOMemAlign = 4096; -const size_t FastOS_Linux_File::_pageSize = 4096; FastOS_Linux_File::FastOS_Linux_File(const char *filename) : FastOS_UNIX_File(filename), diff --git a/fastos/src/vespa/fastos/linux_file.h b/fastos/src/vespa/fastos/linux_file.h index d33884c872a..e304b6f0ce8 100644 --- a/fastos/src/vespa/fastos/linux_file.h +++ b/fastos/src/vespa/fastos/linux_file.h @@ -9,7 +9,7 @@ #pragma once -#include <vespa/fastos/unix_file.h> +#include "unix_file.h" /** * This is the Linux implementation of @ref FastOS_File. Most @@ -57,5 +57,4 @@ private: static const size_t _directIOFileAlign; static const size_t _directIOMemAlign; - static const size_t _pageSize; }; diff --git a/fastos/src/vespa/fastos/unix_file.cpp b/fastos/src/vespa/fastos/unix_file.cpp index fb3bcab6b53..8b01a5255de 100644 --- a/fastos/src/vespa/fastos/unix_file.cpp +++ b/fastos/src/vespa/fastos/unix_file.cpp @@ -173,10 +173,6 @@ FastOS_UNIX_File::Open(unsigned int openFlags, const char *filename) FILE *file; switch(openFlags & FASTOS_FILE_OPEN_STDFLAGS) { - case FASTOS_FILE_OPEN_STDIN: - file = stdin; - SetFileName("stdin"); - break; case FASTOS_FILE_OPEN_STDOUT: file = stdout; |