summaryrefslogtreecommitdiff
path: root/cmdline
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2017-12-13 21:39:16 +0100
committerDavid Kalnischkies <david@kalnischkies.de>2017-12-13 23:53:41 +0100
commit1adcf56bec7d2127d83aa423916639740fe8e586 (patch)
tree39802989990796e903d8e670b07408380b117c21 /cmdline
parent957381a0d26ec11a172ebfc64f892d1b31f0c193 (diff)
avoid some useless casts reported by -Wuseless-cast
The casts are useless, but the reports show some where we can actually improve the code by replacing them with better alternatives like converting whatever int type into a string instead of casting to a specific one which might in the future be too small. Reported-By: gcc -Wuseless-cast
Diffstat (limited to 'cmdline')
-rw-r--r--cmdline/apt-config.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmdline/apt-config.cc b/cmdline/apt-config.cc
index ef1e95de1..4e546b098 100644
--- a/cmdline/apt-config.cc
+++ b/cmdline/apt-config.cc
@@ -128,7 +128,7 @@ int main(int argc,const char *argv[]) /*{{{*/
_config->Set(comp + "Name", c->Name);
_config->Set(comp + "Extension", c->Extension);
_config->Set(comp + "Binary", c->Binary);
- _config->Set(std::string(comp + "Cost").c_str(), c->Cost);
+ _config->Set((comp + "Cost").c_str(), c->Cost);
for (std::vector<std::string>::const_iterator a = c->CompressArgs.begin(); a != c->CompressArgs.end(); ++a)
_config->Set(comp + "CompressArg::", *a);
for (std::vector<std::string>::const_iterator a = c->UncompressArgs.begin(); a != c->UncompressArgs.end(); ++a)