From 24c802b05e3b328fd53d3b3a41f75d9c855b720d Mon Sep 17 00:00:00 2001 From: Koushik Dutta Date: Mon, 11 Jul 2011 14:40:17 -0700 Subject: [PATCH] fix up symlinks and lack of lchmod Change-Id: Iccfddabe239b97a20b0b5302af4488482fffd86b --- dedupe/dedupe.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/dedupe/dedupe.c b/dedupe/dedupe.c index ed11491..1960069 100644 --- a/dedupe/dedupe.c +++ b/dedupe/dedupe.c @@ -297,7 +297,8 @@ int main(int argc, char** argv) { symlink(link, filename); - chmod(filename, mode_oct); + // Android has no lchmod, and chmod follows symlinks + //chmod(filename, mode_oct); lchown(filename, uid_int, gid_int); } else if (strcmp(type, "d") == 0) { @@ -308,6 +309,10 @@ int main(int argc, char** argv) { chmod(filename, mode_oct); chown(filename, uid_int, gid_int); } + else { + fprintf(stderr, "Unknown type %s\n", type); + return 1; + } } fclose(input_manifest);