Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(191)

Unified Diff: sdk/lib/io/process.dart

Issue 11417028: Include command in ProcessException. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« runtime/bin/process_patch.dart ('K') | « runtime/bin/process_patch.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/io/process.dart
diff --git a/sdk/lib/io/process.dart b/sdk/lib/io/process.dart
index 8d6d9f23026f2ea92fd31bfd8e7626a98eebb113..093ed6a18867415fbf963f2f0c594e2784f52221 100644
--- a/sdk/lib/io/process.dart
+++ b/sdk/lib/io/process.dart
@@ -214,8 +214,18 @@ class ProcessSignal {
class ProcessException implements Exception {
- const ProcessException([String this.message = "", int this.errorCode = 0]);
- String toString() => "ProcessException: $message ($errorCode)";
+ const ProcessException([String this.command = "",
+ String this.message = "",
+ int this.errorCode = 0]);
+ String toString() {
+ var msg = (message == null) ? 'OS error code: $errorCode' : message;
+ return "ProcessException: $msg\n Command: $command";
+ }
+
+ /**
+ * Contains the command for this process.
+ */
+ final String command;
/**
* Contains the system message for the process exception if any.
« runtime/bin/process_patch.dart ('K') | « runtime/bin/process_patch.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698