From b54179efa36f08168a7209fb622f161491d75ad6 Mon Sep 17 00:00:00 2001 From: derek Date: Fri, 14 Oct 2011 01:13:30 -0400 Subject: [PATCH] Minor cleanup in FilterTool --- src/toolkit/bamtools_filter.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/toolkit/bamtools_filter.cpp b/src/toolkit/bamtools_filter.cpp index baf2816..8af9cb9 100644 --- a/src/toolkit/bamtools_filter.cpp +++ b/src/toolkit/bamtools_filter.cpp @@ -2,7 +2,7 @@ // bamtools_filter.cpp (c) 2010 Derek Barnett, Erik Garrison // Marth Lab, Department of Biology, Boston College // --------------------------------------------------------------------------- -// Last modified: 7 April 2011 +// Last modified: 14 October 2011 // --------------------------------------------------------------------------- // Filters BAM file(s) according to some user-specified criteria // *************************************************************************** @@ -489,7 +489,7 @@ const string FilterTool::FilterToolPrivate::GetScriptContents(void) { if ( !inFile ) { cerr << "bamtools filter ERROR: could not open script: " << m_settings->ScriptFilename << " for reading" << endl; - return false; + return string(); } // read in entire script contents @@ -505,7 +505,7 @@ const string FilterTool::FilterToolPrivate::GetScriptContents(void) { // read next block of data if ( fgets(buffer, 1024, inFile) == 0 ) { cerr << "bamtools filter ERROR: could not read script contents" << endl; - return false; + return string(); } docStream << buffer; @@ -515,8 +515,7 @@ const string FilterTool::FilterToolPrivate::GetScriptContents(void) { fclose(inFile); // import buffer contents to document, return - string document = docStream.str(); - return document; + return docStream.str(); } void FilterTool::FilterToolPrivate::InitProperties(void) { -- 2.39.2