Loading adb/client/file_sync_client.cpp +4 −4 Original line number Diff line number Diff line Loading @@ -357,7 +357,7 @@ class SyncConnection { << msg.stat_v1.id; } if (msg.stat_v1.mode == 0 && msg.stat_v1.size == 0 && msg.stat_v1.time == 0) { if (msg.stat_v1.mode == 0 && msg.stat_v1.size == 0 && msg.stat_v1.mtime == 0) { // There's no way for us to know what the error was. errno = ENOPROTOOPT; return false; Loading @@ -365,8 +365,8 @@ class SyncConnection { st->st_mode = msg.stat_v1.mode; st->st_size = msg.stat_v1.size; st->st_ctime = msg.stat_v1.time; st->st_mtime = msg.stat_v1.time; st->st_ctime = msg.stat_v1.mtime; st->st_mtime = msg.stat_v1.mtime; } return true; Loading Loading @@ -629,7 +629,7 @@ static bool sync_ls(SyncConnection& sc, const char* path, if (!ReadFdExactly(sc.fd, buf, len)) return false; buf[len] = 0; func(msg.dent.mode, msg.dent.size, msg.dent.time, buf); func(msg.dent.mode, msg.dent.size, msg.dent.mtime, buf); } } Loading adb/daemon/file_sync_service.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -139,7 +139,7 @@ static bool do_lstat_v1(int s, const char* path) { lstat(path, &st); msg.stat_v1.mode = st.st_mode; msg.stat_v1.size = st.st_size; msg.stat_v1.time = st.st_mtime; msg.stat_v1.mtime = st.st_mtime; return WriteFdExactly(s, &msg.stat_v1, sizeof(msg.stat_v1)); } Loading Loading @@ -191,7 +191,7 @@ static bool do_list(int s, const char* path) { size_t d_name_length = strlen(de->d_name); msg.dent.mode = st.st_mode; msg.dent.size = st.st_size; msg.dent.time = st.st_mtime; msg.dent.mtime = st.st_mtime; msg.dent.namelen = d_name_length; if (!WriteFdExactly(s, &msg.dent, sizeof(msg.dent)) || Loading @@ -205,7 +205,7 @@ done: msg.dent.id = ID_DONE; msg.dent.mode = 0; msg.dent.size = 0; msg.dent.time = 0; msg.dent.mtime = 0; msg.dent.namelen = 0; return WriteFdExactly(s, &msg.dent, sizeof(msg.dent)); } Loading adb/file_sync_protocol.h +2 −2 Original line number Diff line number Diff line Loading @@ -42,7 +42,7 @@ union syncmsg { uint32_t id; uint32_t mode; uint32_t size; uint32_t time; uint32_t mtime; } stat_v1; struct __attribute__((packed)) { uint32_t id; Loading @@ -62,7 +62,7 @@ union syncmsg { uint32_t id; uint32_t mode; uint32_t size; uint32_t time; uint32_t mtime; uint32_t namelen; } dent; struct __attribute__((packed)) { Loading Loading
adb/client/file_sync_client.cpp +4 −4 Original line number Diff line number Diff line Loading @@ -357,7 +357,7 @@ class SyncConnection { << msg.stat_v1.id; } if (msg.stat_v1.mode == 0 && msg.stat_v1.size == 0 && msg.stat_v1.time == 0) { if (msg.stat_v1.mode == 0 && msg.stat_v1.size == 0 && msg.stat_v1.mtime == 0) { // There's no way for us to know what the error was. errno = ENOPROTOOPT; return false; Loading @@ -365,8 +365,8 @@ class SyncConnection { st->st_mode = msg.stat_v1.mode; st->st_size = msg.stat_v1.size; st->st_ctime = msg.stat_v1.time; st->st_mtime = msg.stat_v1.time; st->st_ctime = msg.stat_v1.mtime; st->st_mtime = msg.stat_v1.mtime; } return true; Loading Loading @@ -629,7 +629,7 @@ static bool sync_ls(SyncConnection& sc, const char* path, if (!ReadFdExactly(sc.fd, buf, len)) return false; buf[len] = 0; func(msg.dent.mode, msg.dent.size, msg.dent.time, buf); func(msg.dent.mode, msg.dent.size, msg.dent.mtime, buf); } } Loading
adb/daemon/file_sync_service.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -139,7 +139,7 @@ static bool do_lstat_v1(int s, const char* path) { lstat(path, &st); msg.stat_v1.mode = st.st_mode; msg.stat_v1.size = st.st_size; msg.stat_v1.time = st.st_mtime; msg.stat_v1.mtime = st.st_mtime; return WriteFdExactly(s, &msg.stat_v1, sizeof(msg.stat_v1)); } Loading Loading @@ -191,7 +191,7 @@ static bool do_list(int s, const char* path) { size_t d_name_length = strlen(de->d_name); msg.dent.mode = st.st_mode; msg.dent.size = st.st_size; msg.dent.time = st.st_mtime; msg.dent.mtime = st.st_mtime; msg.dent.namelen = d_name_length; if (!WriteFdExactly(s, &msg.dent, sizeof(msg.dent)) || Loading @@ -205,7 +205,7 @@ done: msg.dent.id = ID_DONE; msg.dent.mode = 0; msg.dent.size = 0; msg.dent.time = 0; msg.dent.mtime = 0; msg.dent.namelen = 0; return WriteFdExactly(s, &msg.dent, sizeof(msg.dent)); } Loading
adb/file_sync_protocol.h +2 −2 Original line number Diff line number Diff line Loading @@ -42,7 +42,7 @@ union syncmsg { uint32_t id; uint32_t mode; uint32_t size; uint32_t time; uint32_t mtime; } stat_v1; struct __attribute__((packed)) { uint32_t id; Loading @@ -62,7 +62,7 @@ union syncmsg { uint32_t id; uint32_t mode; uint32_t size; uint32_t time; uint32_t mtime; uint32_t namelen; } dent; struct __attribute__((packed)) { Loading