Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions AmpPlotter/AmpPlotter/PlotterMainWindow.cc
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ m_generator( factory.generator() )
m_canvFrame->AddFrame( m_canvButton, &canvLayoutHints );

// create a button to clear the canvas...
m_clearCanvButton = new TGTextButton( m_canvFrame, "&Clear Canvas", kclearCanv );
m_clearCanvButton = new TGTextButton( m_canvFrame, "&Clear Canvas", kClearCanv );
m_clearCanvButton->Associate( this );
m_clearCanvButton->Resize( kWidth/3, 20 );
m_canvFrame->AddFrame( m_clearCanvButton, &canvLayoutHints );
Expand Down Expand Up @@ -467,7 +467,7 @@ PlotterMainWindow::ProcessMessage( long mes, long p1, long p2 )
}
break;

case kclearCanv:
case kClearCanv:
m_factory.clearCanvas();
break;

Expand Down
26 changes: 14 additions & 12 deletions AmpPlotter/AmpPlotter/PlotterMainWindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,21 +57,23 @@ class PlotterMainWindow : public TGMainFrame

public:

enum { kWidth = 690 };
enum { kHeight = 500 };
enum {
kWidth = 690,
kHeight = 500,

enum { kIndexMask = 0x000000FF };
enum { kButtonMask = 0xFFFFFF00 };
kIndexMask = 0x000000FF,
kButtonMask = 0xFFFFFF00,

enum { kReaction = 0x000100 };
enum { kType = 0x000200 };
enum { kDrawOption = 0x000400 };
kReaction = 0x000100,
kType = 0x000200,
kDrawOption = 0x000400,

enum { kExit, kPlot, kSelectAllAmp, kClearAmp, kSelectAllSum, kClearSum,
kChoosePlot, kChoosePad , kclearCanv, kChooseCanv};
enum { kData, kBkgnd, kAccMC, kGenMC };
enum { kSumSelect, kAmpSelect };
enum { kWeightMC };
kExit = 0, kPlot, kSelectAllAmp, kClearAmp, kSelectAllSum, kClearSum,
kChoosePlot, kChoosePad , kClearCanv, kChooseCanv,
kData=0, kBkgnd, kAccMC, kGenMC,
kSumSelect=0, kAmpSelect,
kWeightMC=0
};

PlotterMainWindow( const TGWindow*, PlotFactory& );

Expand Down
2 changes: 1 addition & 1 deletion AmpTools/IUAmpTools/AmpToolsInterface.cc
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ AmpToolsInterface::forceUserVarRecalculation( bool state ){
float
AmpToolsInterface::random( float randMax ) const {

return ( (float) rand() / RAND_MAX ) * randMax;
return ( (float) rand() / (float) RAND_MAX ) * randMax;
}

void
Expand Down
2 changes: 1 addition & 1 deletion AmpTools/IUAmpToolsMPI/DataReaderMPI.h
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ template< class T >
void DataReaderMPI<T>::defineMPIType()
{

KinStruct kinStruct;
KinStruct kinStruct = {0};

// arrays used to define info about the six elements in the struct
int length[6];
Expand Down
8 changes: 8 additions & 0 deletions AmpTools/UpRootMinuit/URMinuit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6131,11 +6131,19 @@ void URMinuit::mnplot(Double_urt *xpt, Double_urt *ypt, char* chpt, Int_urt nxyp
overpr = kurFALSE;
for (i = 1; i <= ny; ++i) {
for (ibk = 1; ibk <= nx; ++ibk) { cline[ibk-1] = ' '; }
//*-*- gcc can't prove nx/nxbest stay within cline's bounds across the gotos below
#if defined(__GNUC__) && !defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstringop-overflow"
#endif
cline[nx] = '\0';
cline[nx+1] = '\0';
cline[0] = '.';
cline[nx-1] = '.';
cline[nxbest-1] = '.';
#if defined(__GNUC__) && !defined(__clang__)
#pragma GCC diagnostic pop
#endif
if (i != 1 && i != nybest && i != ny) goto L320;
for (j = 1; j <= nx; ++j) { cline[j-1] = '.'; }
L320:
Expand Down
Loading