mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-03-09 15:50:02 +00:00
dtprintinfo: Resolve format-overflow issues
This commit is contained in:
parent
bf266ee14b
commit
16c3ed3650
3 changed files with 4 additions and 4 deletions
|
@ -718,7 +718,7 @@ void DtApp::OpenClose(BaseUI *obj)
|
|||
n_icons = rc->NumChildren();
|
||||
for (i = 0; i < n_jobs; i++)
|
||||
{
|
||||
char number[5];
|
||||
char number[11];
|
||||
sprintf(number, "%d", i + 1);
|
||||
icons[i]->TopString(number);
|
||||
}
|
||||
|
@ -907,7 +907,7 @@ void DtApp::ActionCB(BaseUI *obj, char *actionReferenceName)
|
|||
IconObj **children = (IconObj **)parent->Children();
|
||||
for (i = 0; i < parent->NumChildren(); i++)
|
||||
{
|
||||
char number[5];
|
||||
char number[11];
|
||||
sprintf(number, "%d", i + 1);
|
||||
children[i]->TopString(number);
|
||||
}
|
||||
|
|
|
@ -389,7 +389,7 @@ void DtFindD::Stop()
|
|||
for (i = 0; i < n_matches; i++)
|
||||
{
|
||||
DtPrtJobIcon *job = (DtPrtJobIcon *)matches[i];
|
||||
char number[9];
|
||||
char number[12];
|
||||
sprintf(number, "%d", job->Order() + 1);
|
||||
fields->fields[0] = (char *)job->Parent()->Parent()->Name();
|
||||
if (n_fields == 3)
|
||||
|
|
|
@ -67,7 +67,7 @@ DtPrinterIcon::DtPrinterIcon(DtMainW *mainW, AnyUI *parent, Queue *que,
|
|||
if (app_mode == INITIALIZE_PRINTERS)
|
||||
return;
|
||||
|
||||
char *buf = new char[300];
|
||||
char *buf = new char[sizeof(DtPrinterIcon::homeDir) + 32];
|
||||
struct stat statbuff;
|
||||
if (*homeDir == '\0')
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue