summaryrefslogtreecommitdiff
path: root/klm/util/file.cc
diff options
context:
space:
mode:
authorKenneth Heafield <github@kheafield.com>2012-05-16 13:24:08 -0700
committerChris Dyer <cdyer@cab.ark.cs.cmu.edu>2012-05-26 22:59:54 -0400
commit2b63fa0755954edf467a2421997eaf72771260cf (patch)
treeffb22b22540cd59f20f7de6bfed4313f8b946407 /klm/util/file.cc
parente331ea8e69489cfd727c0ad106c76efa69f3e06c (diff)
Big kenlm change includes lower order models for probing only. And other stuff.
Diffstat (limited to 'klm/util/file.cc')
-rw-r--r--klm/util/file.cc10
1 files changed, 0 insertions, 10 deletions
diff --git a/klm/util/file.cc b/klm/util/file.cc
index de206bc8..1bd056fc 100644
--- a/klm/util/file.cc
+++ b/klm/util/file.cc
@@ -43,16 +43,6 @@ int OpenReadOrThrow(const char *name) {
return ret;
}
-int CreateOrThrow(const char *name) {
- int ret;
-#if defined(_WIN32) || defined(_WIN64)
- UTIL_THROW_IF(-1 == (ret = _open(name, _O_CREAT | _O_TRUNC | _O_RDWR, _S_IREAD | _S_IWRITE)), ErrnoException, "while creating " << name);
-#else
- UTIL_THROW_IF(-1 == (ret = open(name, O_CREAT | O_TRUNC | O_RDWR, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH)), ErrnoException, "while creating " << name);
-#endif
- return ret;
-}
-
uint64_t SizeFile(int fd) {
#if defined(_WIN32) || defined(_WIN64)
__int64 ret = _filelengthi64(fd);