fixes
This commit is contained in:
@@ -177,6 +177,7 @@ strequal
|
|||||||
uring
|
uring
|
||||||
userenv
|
userenv
|
||||||
utimens_impl
|
utimens_impl
|
||||||
|
utimensat
|
||||||
vorbis_version
|
vorbis_version
|
||||||
waggressive
|
waggressive
|
||||||
wall
|
wall
|
||||||
|
@@ -1315,7 +1315,10 @@ auto fuse_drive::utimens_impl(std::string api_path,
|
|||||||
std::string attr) {
|
std::string attr) {
|
||||||
if ((tv == nullptr) || (src.tv_nsec == UTIME_NOW)) {
|
if ((tv == nullptr) || (src.tv_nsec == UTIME_NOW)) {
|
||||||
meta[attr] = std::to_string(utils::time::get_time_now());
|
meta[attr] = std::to_string(utils::time::get_time_now());
|
||||||
} else if (src.tv_nsec != UTIME_OMIT) {
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (src.tv_nsec != UTIME_OMIT) {
|
||||||
meta[attr] = std::to_string(
|
meta[attr] = std::to_string(
|
||||||
src.tv_nsec +
|
src.tv_nsec +
|
||||||
(src.tv_sec * static_cast<std::decay_t<decltype(src.tv_sec)>>(
|
(src.tv_sec * static_cast<std::decay_t<decltype(src.tv_sec)>>(
|
||||||
|
@@ -1010,10 +1010,11 @@ auto remote_server::fuse_utimens(const char *path, const remote::file_time *tv,
|
|||||||
if ((op == UTIME_NOW) || (op == UTIME_OMIT)) {
|
if ((op == UTIME_NOW) || (op == UTIME_OMIT)) {
|
||||||
dst.tv_nsec = static_cast<time_t>(op);
|
dst.tv_nsec = static_cast<time_t>(op);
|
||||||
dst.tv_sec = 0;
|
dst.tv_sec = 0;
|
||||||
} else {
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
dst.tv_nsec = static_cast<time_t>(src % utils::time::NANOS_PER_SECOND);
|
dst.tv_nsec = static_cast<time_t>(src % utils::time::NANOS_PER_SECOND);
|
||||||
dst.tv_sec = static_cast<time_t>(src / utils::time::NANOS_PER_SECOND);
|
dst.tv_sec = static_cast<time_t>(src / utils::time::NANOS_PER_SECOND);
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
process_timespec(op0, tv[0U], tv2[0U]);
|
process_timespec(op0, tv[0U], tv2[0U]);
|
||||||
@@ -1768,7 +1769,7 @@ auto remote_server::update_to_windows_format(json &item) -> json & {
|
|||||||
if (item["meta"][META_WRITTEN].empty() ||
|
if (item["meta"][META_WRITTEN].empty() ||
|
||||||
(item["meta"][META_WRITTEN].get<std::string>() == "0") ||
|
(item["meta"][META_WRITTEN].get<std::string>() == "0") ||
|
||||||
(item["meta"][META_WRITTEN].get<std::string>() ==
|
(item["meta"][META_WRITTEN].get<std::string>() ==
|
||||||
std::to_string(WIN32_TIME_CONVERSION))) {
|
std::to_string(utils::time::WIN32_TIME_CONVERSION))) {
|
||||||
drive_.set_item_meta(api_path, META_WRITTEN,
|
drive_.set_item_meta(api_path, META_WRITTEN,
|
||||||
item["meta"][META_MODIFIED].get<std::string>());
|
item["meta"][META_MODIFIED].get<std::string>());
|
||||||
item["meta"][META_WRITTEN] = item["meta"][META_MODIFIED];
|
item["meta"][META_WRITTEN] = item["meta"][META_MODIFIED];
|
||||||
|
Reference in New Issue
Block a user