1
0
mirror of git://projects.qi-hardware.com/eda-tools.git synced 2024-11-04 23:29:42 +02:00

eeshow/delta.c (sheet_eq): check if one sheet title is NULL

May have caused a segfault.
This commit is contained in:
Werner Almesberger 2016-08-16 03:47:35 -03:00
parent c5fcf2c16e
commit e349ae0d1f

View File

@ -303,8 +303,12 @@ bool sheet_eq(const struct sheet *a, const struct sheet *b)
if (!(a && b))
return 0;
if (a->title != b->title && strcmp(a->title, b->title))
return 0;
if (a->title != b->title) {
if (!a->title || !b->title)
return 0;
if (strcmp(a->title, b->title))
return 0;
}
obj_a = a->objs;
obj_b = b->objs;