[Lldb-commits] [PATCH] D107664: [lldb] [Commands] Remove 'append' from 'platform file open' mode
Michał Górny via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed Sep 8 06:42:33 PDT 2021
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG2c6d90d7410b: [lldb] [Commands] Remove 'append' from 'platform file open' mode (authored by mgorny).
Herald added a project: LLDB.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D107664/new/
https://reviews.llvm.org/D107664
Files:
lldb/source/Commands/CommandObjectPlatform.cpp
lldb/test/API/functionalities/gdb_remote_client/TestGDBRemotePlatformFile.py
Index: lldb/test/API/functionalities/gdb_remote_client/TestGDBRemotePlatformFile.py
===================================================================
--- lldb/test/API/functionalities/gdb_remote_client/TestGDBRemotePlatformFile.py
+++ lldb/test/API/functionalities/gdb_remote_client/TestGDBRemotePlatformFile.py
@@ -34,7 +34,7 @@
self.match("platform file close 16",
[r"file 16 closed."])
self.assertPacketLogContains([
- "vFile:open:2f736f6d652f66696c652e747874,0000020a,000001ed",
+ "vFile:open:2f736f6d652f66696c652e747874,00000202,000001ed",
"vFile:pread:10,d,b",
"vFile:pwrite:10,b,teststring",
"vFile:close:10",
@@ -70,7 +70,7 @@
[r"error: Invalid argument"],
error=True)
self.assertPacketLogContains([
- "vFile:open:2f736f6d652f66696c652e747874,0000020a,000001ed",
+ "vFile:open:2f736f6d652f66696c652e747874,00000202,000001ed",
"vFile:pread:10,d,b",
"vFile:pwrite:10,b,teststring",
"vFile:close:10",
Index: lldb/source/Commands/CommandObjectPlatform.cpp
===================================================================
--- lldb/source/Commands/CommandObjectPlatform.cpp
+++ lldb/source/Commands/CommandObjectPlatform.cpp
@@ -498,8 +498,7 @@
lldb::eFilePermissionsWorldRead;
lldb::user_id_t fd = platform_sp->OpenFile(
FileSpec(cmd_line),
- File::eOpenOptionReadWrite | File::eOpenOptionAppend |
- File::eOpenOptionCanCreate,
+ File::eOpenOptionReadWrite | File::eOpenOptionCanCreate,
perms, error);
if (error.Success()) {
result.AppendMessageWithFormat("File Descriptor = %" PRIu64 "\n", fd);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D107664.371327.patch
Type: text/x-patch
Size: 1872 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20210908/f2ba83cb/attachment.bin>
More information about the lldb-commits
mailing list