MCPcopy Create free account
hub / github.com/AGWA/git-crypt / create_protected_file

Function create_protected_file

util-unix.cpp:168–175  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

166}
167
168void create_protected_file (const char* path)
169{
170 int fd = open(path, O_WRONLY | O_CREAT, 0600);
171 if (fd == -1) {
172 throw System_error("open", path, errno);
173 }
174 close(fd);
175}
176
177int util_rename (const char* from, const char* to)
178{

Callers 1

store_to_fileMethod · 0.70

Calls 1

System_errorClass · 0.85

Tested by

no test coverage detected