MCPcopy Create free account
hub / github.com/catboost/catboost / ftruncate

Function ftruncate

util/system/compat.cpp:28–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26
27 #include <fcntl.h>
28int ftruncate(int fd, i64 length) {
29 return _chsize_s(fd, length);
30}
31int truncate(const char* name, i64 length) {
32 int fd = ::_open(name, _O_WRONLY);
33 int ret = ftruncate(fd, length);

Callers 4

ResizeMethod · 0.70
ShrinkToFitMethod · 0.70
truncateFunction · 0.70
CreateOpenImplMethod · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected