diff options
author | Mark Salyzyn <salyzyn@google.com> | 2014-05-23 17:51:55 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2014-05-23 17:51:55 +0000 |
commit | 0520298e3a58c99bc87a4e8c5f64aa419354159b (patch) | |
tree | 1092e82e78fc582a79cda344445c2f09eca00c6a | |
parent | 04482eaba2584c3a05bff4a6647f0a2e55475a91 (diff) | |
parent | 0b17e1cf18def9830983aa5c37c7c62e83cf0169 (diff) | |
download | system_core-0520298e3a58c99bc87a4e8c5f64aa419354159b.zip system_core-0520298e3a58c99bc87a4e8c5f64aa419354159b.tar.gz system_core-0520298e3a58c99bc87a4e8c5f64aa419354159b.tar.bz2 |
am 0b17e1cf: am 72be6d5e: Merge "cpio: Turn on -Werror"
* commit '0b17e1cf18def9830983aa5c37c7c62e83cf0169':
cpio: Turn on -Werror
-rw-r--r-- | cpio/Android.mk | 2 | ||||
-rw-r--r-- | cpio/mkbootfs.c | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/cpio/Android.mk b/cpio/Android.mk index 5184463..575beb2 100644 --- a/cpio/Android.mk +++ b/cpio/Android.mk @@ -8,6 +8,8 @@ LOCAL_SRC_FILES := \ LOCAL_MODULE := mkbootfs +LOCAL_CFLAGS := -Werror + include $(BUILD_HOST_EXECUTABLE) $(call dist-for-goals,dist_files,$(LOCAL_BUILT_MODULE)) diff --git a/cpio/mkbootfs.c b/cpio/mkbootfs.c index 7d3740c..7175749 100644 --- a/cpio/mkbootfs.c +++ b/cpio/mkbootfs.c @@ -78,8 +78,9 @@ static void fix_stat(const char *path, struct stat *s) s->st_mode = empty_path_config->mode | (s->st_mode & ~07777); } else { // Use the compiled-in fs_config() function. - - fs_config(path, S_ISDIR(s->st_mode), &s->st_uid, &s->st_gid, &s->st_mode, &capabilities); + unsigned st_mode = s->st_mode; + fs_config(path, S_ISDIR(s->st_mode), &s->st_uid, &s->st_gid, &st_mode, &capabilities); + s->st_mode = (typeof(s->st_mode)) st_mode; } } |