summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTzafrir Cohen <tzafrir@cohens.org.il>2012-09-26 20:05:00 +0200
committerTzafrir Cohen <tzafrir@cohens.org.il>2012-09-26 20:05:00 +0200
commit5f9f92ff75ebb1492fba730e6d30ad2ed61845df (patch)
treeef33c0b047c6e6c1ea9d49f93d9e8081c4d88518
parenta4fbead419b4bb121ca73cff38daf6f31ec321a4 (diff)
re-use original argv[0] when rebuilding argv
I broke the generation of argv: did not include adding argv[0] in it. This re-adds argv[0], but uses the original one from the command line rather than a constant string. This also avoids a warning of using a constant string for char** which is argv.
-rw-r--r--main.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/main.cc b/main.cc
index f533b74..c7abd90 100644
--- a/main.cc
+++ b/main.cc
@@ -281,8 +281,7 @@ int main(int argc, char *argv[])
*/
ArgsList arguments;
- // FIXME: removed. Seems odd and gives a warning (Tzafrir).
- //arguments.push_back(PACKAGE); // push argv[0] (our program name)
+ arguments.push_back(argv[0]); // push argv[0] (our program name)
// Read arguments from the RC file.
// first, read the RC file pointed to by $PACKAGE_RC.