Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
M
Magisk
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Magisk
Commits
50b55a77
Commit
50b55a77
authored
Jan 20, 2019
by
topjohnwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't mount images when running core-only mode
parent
fdf167db
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
bootstages.cpp
native/jni/daemon/bootstages.cpp
+9
-9
No files found.
native/jni/daemon/bootstages.cpp
View file @
50b55a77
...
@@ -779,7 +779,7 @@ void startup() {
...
@@ -779,7 +779,7 @@ void startup() {
execl
(
"/sbin/magisk.bin"
,
"magisk"
,
"--post-fs-data"
,
nullptr
);
execl
(
"/sbin/magisk.bin"
,
"magisk"
,
"--post-fs-data"
,
nullptr
);
}
}
[[
noreturn
]]
static
void
core_only
()
{
[[
noreturn
]]
static
inline
void
core_only
()
{
auto_start_magiskhide
();
auto_start_magiskhide
();
unblock_boot_process
();
unblock_boot_process
();
}
}
...
@@ -800,6 +800,14 @@ void post_fs_data(int client) {
...
@@ -800,6 +800,14 @@ void post_fs_data(int client) {
start_log_daemon
();
start_log_daemon
();
// Run common scripts
LOGI
(
"* Running post-fs-data.d scripts
\n
"
);
exec_common_script
(
"post-fs-data"
);
// Core only mode
if
(
access
(
DISABLEFILE
,
F_OK
)
==
0
)
core_only
();
if
(
!
prepare_img
())
{
if
(
!
prepare_img
())
{
LOGE
(
"* Magisk image mount failed, switch to core-only mode
\n
"
);
LOGE
(
"* Magisk image mount failed, switch to core-only mode
\n
"
);
free
(
magiskloop
);
free
(
magiskloop
);
...
@@ -810,14 +818,6 @@ void post_fs_data(int client) {
...
@@ -810,14 +818,6 @@ void post_fs_data(int client) {
restorecon
();
restorecon
();
chmod
(
SECURE_DIR
,
0700
);
chmod
(
SECURE_DIR
,
0700
);
// Run common scripts
LOGI
(
"* Running post-fs-data.d scripts
\n
"
);
exec_common_script
(
"post-fs-data"
);
// Core only mode
if
(
access
(
DISABLEFILE
,
F_OK
)
==
0
)
core_only
();
// Execute module scripts
// Execute module scripts
LOGI
(
"* Running module post-fs-data scripts
\n
"
);
LOGI
(
"* Running module post-fs-data scripts
\n
"
);
exec_module_script
(
"post-fs-data"
);
exec_module_script
(
"post-fs-data"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment