mirror of
https://gitea.psi.ch/ELOG/elog.git
synced 2026-09-10 18:23:28 +00:00
Prevent crash if logbook "global<xxx>" is accessed and a logbook "global<xxx>" is defined in config file
SVN revision: 1748
This commit is contained in:
parent
e93b0091cf
commit
4a6fae7528
@ -2645,9 +2645,13 @@ int is_logbook(char *logbook)
|
|||||||
{
|
{
|
||||||
char str[256];
|
char str[256];
|
||||||
|
|
||||||
|
if (strieq(logbook, "global"))
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
/* check for 'global group' or 'global_xxx' */
|
||||||
strlcpy(str, logbook, sizeof(str));
|
strlcpy(str, logbook, sizeof(str));
|
||||||
str[6] = 0;
|
str[7] = 0;
|
||||||
return !strieq(str, "global");
|
return !strieq(str, "global ");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*-------------------------------------------------------------------*/
|
/*-------------------------------------------------------------------*/
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user