summaryrefslogtreecommitdiffstats
path: root/twrpTar.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--twrpTar.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/twrpTar.cpp b/twrpTar.cpp
index 27c7c7b1b..4a71159cc 100644
--- a/twrpTar.cpp
+++ b/twrpTar.cpp
@@ -987,7 +987,7 @@ int twrpTar::createTar() {
fd = pipes[1];
init_libtar_no_buffer(progress_pipe_fd);
tar_type.writefunc = write_tar_no_buffer;
- if(tar_fdopen(&t, fd, charRootDir, &tar_type, O_WRONLY | O_CREAT | O_EXCL | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
+ if (tar_fdopen(&t, fd, charRootDir, &tar_type, O_WRONLY | O_CREAT | O_EXCL | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
close(fd);
LOGINFO("tar_fdopen failed\n");
gui_err("backup_error=Error creating backup.");
@@ -1047,7 +1047,7 @@ int twrpTar::createTar() {
fd = pigzfd[1]; // copy parent output
init_libtar_no_buffer(progress_pipe_fd);
tar_type.writefunc = write_tar_no_buffer;
- if(tar_fdopen(&t, fd, charRootDir, &tar_type, O_WRONLY | O_CREAT | O_EXCL | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
+ if (tar_fdopen(&t, fd, charRootDir, &tar_type, O_WRONLY | O_CREAT | O_EXCL | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
close(fd);
LOGINFO("tar_fdopen failed\n");
gui_err("backup_error=Error creating backup.");
@@ -1097,7 +1097,7 @@ int twrpTar::createTar() {
fd = oaesfd[1]; // copy parent output
init_libtar_no_buffer(progress_pipe_fd);
tar_type.writefunc = write_tar_no_buffer;
- if(tar_fdopen(&t, fd, charRootDir, &tar_type, O_WRONLY | O_CREAT | O_EXCL | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
+ if (tar_fdopen(&t, fd, charRootDir, &tar_type, O_WRONLY | O_CREAT | O_EXCL | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
close(fd);
LOGINFO("tar_fdopen failed\n");
gui_err("backup_error=Error creating backup.");
@@ -1220,7 +1220,7 @@ int twrpTar::openTar() {
close(pipes[1]);
close(pipes[3]);
fd = pipes[2];
- if(tar_fdopen(&t, fd, charRootDir, NULL, O_RDONLY | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
+ if (tar_fdopen(&t, fd, charRootDir, NULL, O_RDONLY | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
close(fd);
LOGINFO("tar_fdopen failed\n");
gui_err("restore_error=Error during restore process.");
@@ -1270,7 +1270,7 @@ int twrpTar::openTar() {
// Parent
close(oaesfd[1]); // close parent output
fd = oaesfd[0]; // copy parent input
- if(tar_fdopen(&t, fd, charRootDir, NULL, O_RDONLY | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
+ if (tar_fdopen(&t, fd, charRootDir, NULL, O_RDONLY | O_LARGEFILE, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH, TWTAR_FLAGS) != 0) {
close(fd);
LOGINFO("tar_fdopen failed\n");
gui_err("restore_error=Error during restore process.");
@@ -1536,7 +1536,7 @@ unsigned long long twrpTar::uncompressedSize(string filename) {
*/
split = TWFunc::split_string(result, ' ', true);
if (split.size() > 4)
- total_size = atoi(split[5].c_str());
+ total_size = atoi(split[5].c_str());
}
} else if (current_archive_type == COMPRESSED_ENCRYPTED) {
// File is encrypted and may be compressed
@@ -1562,7 +1562,7 @@ unsigned long long twrpTar::uncompressedSize(string filename) {
*/
split = TWFunc::split_string(result, ' ', true);
if (split.size() > 4)
- total_size = atoi(split[5].c_str());
+ total_size = atoi(split[5].c_str());
}
} else {
total_size = TWFunc::Get_File_Size(filename);