Skip to content

Commit

Permalink
Force maxAddr to be at least 2
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkRivers committed Apr 4, 2019
1 parent 8c2ba1e commit f485e0b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ADApp/pluginSrc/NDPluginAttribute.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include <string.h>
#include <stdio.h>
#include <math.h>
#include <algorithm>

#include <epicsTypes.h>
#include <epicsMessageQueue.h>
Expand Down Expand Up @@ -179,7 +180,7 @@ NDPluginAttribute::NDPluginAttribute(const char *portName, int queueSize, int bl
int priority, int stackSize)
/* Invoke the base class constructor */
: NDPluginDriver(portName, queueSize, blockingCallbacks,
NDArrayPort, NDArrayAddr, maxAttributes, maxBuffers, maxMemory,
NDArrayPort, NDArrayAddr, std::max<int>(maxAttributes,2), maxBuffers, maxMemory,
asynInt32ArrayMask | asynFloat64Mask | asynFloat64ArrayMask | asynGenericPointerMask,
asynInt32ArrayMask | asynFloat64Mask | asynFloat64ArrayMask | asynGenericPointerMask,
ASYN_MULTIDEVICE, 1, priority, stackSize, 1)
Expand Down

0 comments on commit f485e0b

Please sign in to comment.