From bb3e5351b43100ff142d298d226d106b206927cc Mon Sep 17 00:00:00 2001 From: Dhanya Maliakal Date: Mon, 11 Dec 2017 13:51:11 +0100 Subject: [PATCH] solving warnings from latest linux --- slsDetectorGui/src/qDrawPlot.cpp | 2 +- slsDetectorSoftware/slsDetector/slsDetector.cpp | 2 +- slsReceiverSoftware/src/UDPStandardImplementation.cpp | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/slsDetectorGui/src/qDrawPlot.cpp b/slsDetectorGui/src/qDrawPlot.cpp index 89ff503ee..c1790aeed 100644 --- a/slsDetectorGui/src/qDrawPlot.cpp +++ b/slsDetectorGui/src/qDrawPlot.cpp @@ -228,7 +228,7 @@ void qDrawPlot::SetupWidgetWindow(){ layout = new QGridLayout; this->setLayout(layout); - histFrameIndexTitle= histFrameIndexTitle = new QLabel(""); + histFrameIndexTitle = new QLabel(""); boxPlot = new QGroupBox(""); layout->addWidget(boxPlot,1,0); diff --git a/slsDetectorSoftware/slsDetector/slsDetector.cpp b/slsDetectorSoftware/slsDetector/slsDetector.cpp index 9f3d8b4de..d1acd73ed 100644 --- a/slsDetectorSoftware/slsDetector/slsDetector.cpp +++ b/slsDetectorSoftware/slsDetector/slsDetector.cpp @@ -3839,7 +3839,7 @@ slsDetectorDefs::detectorSettings slsDetector::setSettings( detectorSettings ise if(gainval) delete [] gainval; if(offsetval) delete [] offsetval; - switch(thisDetector->myDetectorType==MYTHEN){ + if (thisDetector->myDetectorType==MYTHEN){ if (thisDetector->correctionMask&(1<ResetParametersforNewMeasurement(); if (dataStreamEnable) { - char fnametostream[1000]; - sprintf(fnametostream, "%s/%s", filePath, fileName); + char fnametostream[MAX_STR_LENGTH]; + snprintf(fnametostream, MAX_STR_LENGTH, "%s/%s", filePath, fileName); for (vector::const_iterator it = dataStreamer.begin(); it != dataStreamer.end(); ++it) (*it)->ResetParametersforNewMeasurement(fnametostream); }