aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/MacroCommand.cc
diff options
context:
space:
mode:
authorPavel Labath <pavelo@centrum.sk>2011-07-22 15:52:58 (GMT)
committerPavel Labath <pavelo@centrum.sk>2011-09-14 17:39:11 (GMT)
commitd21ceb4a235d8f8994390d7bc7611b990e6c0c31 (patch)
tree909bd768f8b9893e0a425d01ef63e10185bfd3ac /src/FbTk/MacroCommand.cc
parent1f34dee9b3ce82a2b9f3578ecb14ad3c59080c46 (diff)
downloadfluxbox_pavel-d21ceb4a235d8f8994390d7bc7611b990e6c0c31.zip
fluxbox_pavel-d21ceb4a235d8f8994390d7bc7611b990e6c0c31.tar.bz2
Remove the assignment operator from a regular pointer to a RefCount
it is too easy too shoot yourself in the foot with it, other smart pointers also don't allow such assignments. If you do want to assign to a RefCount pointer, use reset(). ps: assignment between two RefCounts remains possible, of course.
Diffstat (limited to 'src/FbTk/MacroCommand.cc')
-rw-r--r--src/FbTk/MacroCommand.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/FbTk/MacroCommand.cc b/src/FbTk/MacroCommand.cc
index e04d92a..549f2da 100644
--- a/src/FbTk/MacroCommand.cc
+++ b/src/FbTk/MacroCommand.cc
@@ -41,7 +41,7 @@ M *addCommands(M *macro, const std::string &args, bool trusted) {
41 if (remainder.length() == 0) { 41 if (remainder.length() == 0) {
42 std::list<std::string>::iterator it = cmds.begin(), it_end = cmds.end(); 42 std::list<std::string>::iterator it = cmds.begin(), it_end = cmds.end();
43 for (; it != it_end; ++it) { 43 for (; it != it_end; ++it) {
44 cmd = CommandParser<void>::instance().parse(*it, trusted); 44 cmd.reset( CommandParser<void>::instance().parse(*it, trusted) );
45 if (cmd) 45 if (cmd)
46 macro->add(cmd); 46 macro->add(cmd);
47 } 47 }