Skip to content

Commit

Permalink
darwinup: Touch /System/Library/Extensions when uninstalling kernel e…
Browse files Browse the repository at this point in the history
…xtensions.

git-svn-id: https://svn.macosforge.org/repository/darwinbuild/trunk@1010 10a61168-4876-4dac-953b-31e694342555
  • Loading branch information
mwwa committed Feb 8, 2012
1 parent 8495172 commit d38b47e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions darwinup/Depot.cpp
Expand Up @@ -994,6 +994,11 @@ int Depot::uninstall_file(File* file, void* ctx) {
} else {
IF_DEBUG("[uninstall] no changes; leaving in place\n");
}
if (!context->depot->m_modified_extensions &&
(strncmp(file->path(), "/System/Library/Extensions", 26) == 0)) {
IF_DEBUG("[uninstall] kernel extension detected\n");
context->depot->m_modified_extensions = true;
}
}
uint32_t info = preceding->info();
if (INFO_TEST(info, FILE_INFO_NO_ENTRY | FILE_INFO_ROLLBACK_DATA) &&
Expand Down
1 change: 1 addition & 0 deletions darwinup/main.cpp
Expand Up @@ -273,6 +273,7 @@ int main(int argc, char* argv[]) {
if (!disable_automation && depot->has_modified_extensions() && res == 0) {
char *sle_path;
res = join_path(&sle_path, depot->prefix(), "/System/Library/Extensions");
IF_DEBUG("Touching /System/Library/Extensions\n");
if (res == 0) res = utimes(sle_path, NULL);
if (res) {
fprintf(stderr, "Warning: unable to touch %s \n", sle_path);
Expand Down

0 comments on commit d38b47e

Please sign in to comment.