summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxiaolu <server@163.com>2015-05-26 16:55:18 +0200
committerEthan Yonker <dees_troy@teamw.in>2015-12-22 19:19:12 +0100
commit38c3aa78caf05c230f409df68f0a3f8769198bc5 (patch)
tree9e0ea943aec9034a920606095c129169f82c8e83
parentselinux: Only union sepolicy in SDKs 21,22 (diff)
downloadandroid_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.tar
android_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.tar.gz
android_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.tar.bz2
android_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.tar.lz
android_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.tar.xz
android_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.tar.zst
android_bootable_recovery-38c3aa78caf05c230f409df68f0a3f8769198bc5.zip
-rw-r--r--openrecoveryscript.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/openrecoveryscript.cpp b/openrecoveryscript.cpp
index ebf765441..b31a7605f 100644
--- a/openrecoveryscript.cpp
+++ b/openrecoveryscript.cpp
@@ -420,12 +420,12 @@ int OpenRecoveryScript::run_script_file(void) {
}
int OpenRecoveryScript::Insert_ORS_Command(string Command) {
- ofstream ORSfile(SCRIPT_FILE_TMP);
+ ofstream ORSfile(SCRIPT_FILE_TMP, ios_base::app | ios_base::out);
if (ORSfile.is_open()) {
//if (Command.substr(Command.size() - 1, 1) != "\n")
// Command += "\n";
LOGINFO("Inserting '%s'\n", Command.c_str());
- ORSfile << Command.c_str();
+ ORSfile << Command.c_str() << endl;
ORSfile.close();
return 1;
}