From: Jon Trulson Date: Tue, 7 May 2019 00:23:36 +0000 (-0600) Subject: dtprintinfo: correct another possible buffer overflow X-Git-Tag: 2.3.0a~13 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=05d231606ebe3658712a36017d16ec3cc349145d;p=oweals%2Fcde.git dtprintinfo: correct another possible buffer overflow --- diff --git a/cde/programs/dtprintinfo/objects/PrintObj/Queue.C b/cde/programs/dtprintinfo/objects/PrintObj/Queue.C index a5c102ba..c1c3ae58 100644 --- a/cde/programs/dtprintinfo/objects/PrintObj/Queue.C +++ b/cde/programs/dtprintinfo/objects/PrintObj/Queue.C @@ -336,7 +336,7 @@ int Queue::Stop(BaseObj *obj, char **output, BaseObj * /*requestor*/) else #endif { - sprintf(command, STOP_QUEUE_CMD, queue->Name()); + snprintf(command, 100, STOP_QUEUE_CMD, queue->Name()); rc = queue->RunCommand(command, NULL, output); } delete [] command;