- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for Transfer (0.18 sec)
-
tensorflow/c/experimental/filesystem/plugins/posix/posix_filesystem_helper.cc
// If file exists, truncate its size to 0. int dst_fd = open(dst, O_WRONLY | O_CREAT | O_TRUNC, open_mode); if (dst_fd < 0) { close(src_fd); return -1; } // Both files have been opened, do the transfer. // Since errno would be overridden by `close` below, save it here. int error_code = 0; if (CopyFileContents(dst_fd, src_fd, size) < 0) error_code = errno; close(src_fd); close(dst_fd);
C++ - Registered: Tue Apr 23 12:39:09 GMT 2024 - Last Modified: Thu Jan 16 05:36:52 GMT 2020 - 2.1K bytes - Viewed (1) -
tensorflow/c/experimental/filesystem/plugins/posix/copy_file_portable.cc
#include <stdint.h> #include <unistd.h> #include <memory> #include "tensorflow/c/experimental/filesystem/plugins/posix/copy_file.h" namespace tf_posix_filesystem { // Transfers up to `size` bytes from `dst_fd` to `src_fd`. // // This method uses a temporary buffer to hold contents. int CopyFileContents(int dst_fd, int src_fd, off_t size) {
C++ - Registered: Tue Apr 23 12:39:09 GMT 2024 - Last Modified: Fri Nov 22 21:23:55 GMT 2019 - 1.9K bytes - Viewed (0) -
tensorflow/c/experimental/filesystem/plugins/posix/copy_file_linux.cc
#include <limits.h> #include <stdint.h> #include <sys/sendfile.h> #include "tensorflow/c/experimental/filesystem/plugins/posix/copy_file.h" namespace tf_posix_filesystem { // Transfers up to `size` bytes from `dst_fd` to `src_fd`. // // This method uses `sendfile` specific to linux after 2.6.33. int CopyFileContents(int dst_fd, int src_fd, off_t size) { off_t offset = 0; int bytes_transferred = 0;
C++ - Registered: Tue Apr 23 12:39:09 GMT 2024 - Last Modified: Fri Nov 22 21:23:55 GMT 2019 - 1.5K bytes - Viewed (0)