- After a bug at TRICS I replaced all occurrences of strcpy, strcat, sprintf
by length limited versions wherever appropriate. SKIPPED: psi/el755driv.c psi/faverage.c psi/frame.c psi/lmd200.c psi/polterwrite.c psi/psi.c psi/sanswave.c psi/sinqhmdriv.c psi/termprot.c
This commit is contained in:
4
alias.c
4
alias.c
@ -69,7 +69,7 @@ int SicsAlias(SConnection * pCon, SicsInterp * pSics, void *pData,
|
||||
/* first parameter should be an registered SICS object */
|
||||
pCom = FindCommand(pSics, argv[1]);
|
||||
if (!pCom) {
|
||||
sprintf(pBueffel, "ERROR: cannot find %s, no alias created", argv[1]);
|
||||
snprintf(pBueffel,255, "ERROR: cannot find %s, no alias created", argv[1]);
|
||||
SCWrite(pCon, pBueffel, eError);
|
||||
return 0;
|
||||
}
|
||||
@ -77,7 +77,7 @@ int SicsAlias(SConnection * pCon, SicsInterp * pSics, void *pData,
|
||||
/* alright: create the alias */
|
||||
iRet = AddCommand(pSics, argv[2], pCom->OFunc, NULL, pCom->pData);
|
||||
if (!iRet) {
|
||||
sprintf(pBueffel, "ERROR: duplicate command %s not created", argv[2]);
|
||||
snprintf(pBueffel,255, "ERROR: duplicate command %s not created", argv[2]);
|
||||
SCWrite(pCon, pBueffel, eError);
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user