[med-svn] [SCM] aghermann branch, master, updated. 3603e7ef1289f9ec79a3eb415b6d141166e9498a
Andrei Zavada
johnhommer at gmail.com
Sun Jul 14 22:28:19 UTC 2013
The following commit has been merged in the master branch:
commit 5bf60d0e92a757431cf1cef260a8cf56531ae75e
Author: Andrei Zavada <johnhommer at gmail.com>
Date: Wed Jul 10 01:22:28 2013 +0300
think straight in CTypedSource ctor by rvalue
diff --git a/src/libsigfile/source.cc b/src/libsigfile/source.cc
index d825123..f5ffe73 100644
--- a/src/libsigfile/source.cc
+++ b/src/libsigfile/source.cc
@@ -64,10 +64,10 @@ CTypedSource (CTypedSource&& rv)
{
switch ( _type = rv._type ) {
case TType::ascii:
- _obj = new CTSVFile( move(*static_cast<CTSVFile*>(rv._obj)));
+ _obj = static_cast<CTSVFile*> (rv._obj);
break;
case TType::edf:
- _obj = new CEDFFile( move(*static_cast<CEDFFile*>(rv._obj)));
+ _obj = static_cast<CEDFFile*> (rv._obj);
break;
case TType::bin:
@@ -78,7 +78,6 @@ CTypedSource (CTypedSource&& rv)
throw invalid_argument ("Bad source type");
}
- delete rv._obj;
rv._obj = nullptr;
}
--
Sleep experiment manager
More information about the debian-med-commit
mailing list