summaryrefslogtreecommitdiff
path: root/apt-pkg/cdrom.cc
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2014-02-27 02:18:11 +0100
committerDavid Kalnischkies <david@kalnischkies.de>2014-03-13 13:58:45 +0100
commite788a834ce421042e727b72e43177edaa47e53a7 (patch)
treef60be8202f04cc1ef759bdaff6c0a1d95fd59306 /apt-pkg/cdrom.cc
parentcf4ff3b78dc347188949370db914fe6329be6c99 (diff)
warning: useless cast to type A [-Wuseless-cast]
Git-Dch: Ignore Reported-By: gcc -Wuseless-cast
Diffstat (limited to 'apt-pkg/cdrom.cc')
-rw-r--r--apt-pkg/cdrom.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/apt-pkg/cdrom.cc b/apt-pkg/cdrom.cc
index 838c8887a..ea5ed7e92 100644
--- a/apt-pkg/cdrom.cc
+++ b/apt-pkg/cdrom.cc
@@ -440,7 +440,7 @@ bool pkgCdrom::WriteDatabase(Configuration &Cnf)
Out.close();
if (FileExists(DFile) == true)
- rename(DFile.c_str(), string(DFile + '~').c_str());
+ rename(DFile.c_str(), (DFile + '~').c_str());
if (rename(NewFile.c_str(),DFile.c_str()) != 0)
return _error->Errno("rename","Failed to rename %s.new to %s",
DFile.c_str(),DFile.c_str());
@@ -553,7 +553,7 @@ bool pkgCdrom::WriteSourceList(string Name,vector<string> &List,bool Source)
Out.close();
- rename(File.c_str(),string(File + '~').c_str());
+ rename(File.c_str(), (File + '~').c_str());
if (rename(NewFile.c_str(),File.c_str()) != 0)
return _error->Errno("rename","Failed to rename %s.new to %s",
File.c_str(),File.c_str());
@@ -737,7 +737,7 @@ bool pkgCdrom::Add(pkgCdromStatus *log) /*{{{*/
if (InfoDir.empty() == false &&
FileExists(InfoDir + "/info") == true)
{
- ifstream F(string(InfoDir + "/info").c_str());
+ ifstream F((InfoDir + "/info").c_str());
if (!F == 0)
getline(F,Name);
@@ -981,7 +981,7 @@ pkgUdevCdromDevices::ScanForRemovable(bool CdromOnly)
cdrom.DeviceName = string(devnode);
if (mountpath != "") {
cdrom.MountPath = mountpath;
- string s = string(mountpath);
+ string s = mountpath;
cdrom.Mounted = IsMounted(s);
} else {
cdrom.Mounted = false;