aboutsummaryrefslogtreecommitdiff
path: root/src/toast.c
diff options
context:
space:
mode:
authorJan200101 <sentrycraft123@gmail.com>2022-09-11 14:39:24 +0200
committerJan200101 <sentrycraft123@gmail.com>2022-09-11 14:39:24 +0200
commit37de0cc7b0eeeefcc25173913faaefa2a7673d2c (patch)
tree33a216d1c211e00aff2035e929d304768e5064e1 /src/toast.c
parent7809edab2aab5701f7be3f278b10e030e944477e (diff)
downloadOFQT-37de0cc7b0eeeefcc25173913faaefa2a7673d2c.tar.gz
OFQT-37de0cc7b0eeeefcc25173913faaefa2a7673d2c.zip
rename force update to verify, reorder updates, return rename retval
Diffstat (limited to 'src/toast.c')
-rw-r--r--src/toast.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/toast.c b/src/toast.c
index c054e2f..0d3ac3a 100644
--- a/src/toast.c
+++ b/src/toast.c
@@ -149,7 +149,7 @@ void setLocalRevision(char* dir, int rev)
return;
// cleanup legacy behavior
- {
+ {
char* old_revision_path = malloc(strlen(revision_path) + strlen(OLD_TOAST_LOCAL_REVISION_PATH));
strcpy(old_revision_path, revision_path);
@@ -542,12 +542,12 @@ int applyObject(char* path, struct file_info* info)
char* buf_file = malloc(len);
snprintf(buf_file, len, "%s%s%s", path, OS_PATH_SEP, file);
- rename(buf_obj, buf_file);
+ int retval = rename(buf_obj, buf_file);
free(buf_obj);
free(buf_file);
- return 0;
+ return retval;
}
/**