After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 689376 - Don't iterate over a NULL strv
Don't iterate over a NULL strv
Status: RESOLVED FIXED
Product: gdm
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: GDM maintainers
GDM maintainers
Depends on:
Blocks:
 
 
Reported: 2012-11-30 20:25 UTC by Matthias Clasen
Modified: 2012-12-01 00:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Don't iterate over a NULL strv (1.13 KB, patch)
2012-11-30 20:25 UTC, Matthias Clasen
committed Details | Review

Description Matthias Clasen 2012-11-30 20:25:06 UTC
sd_seat_get_sessions is documented as 'may return an empty array
or NULL', so we should be careful to not crash if it _does_ return
NULL.

Coverity complained about this.
Comment 1 Matthias Clasen 2012-11-30 20:25:08 UTC
Created attachment 230338 [details] [review]
Don't iterate over a NULL strv
Comment 2 Ray Strode [halfline] 2012-11-30 22:10:33 UTC
Review of attachment 230338 [details] [review]:

sure
Comment 3 Matthias Clasen 2012-12-01 00:20:37 UTC
Attachment 230338 [details] pushed as 143e044 - Don't iterate over a NULL strv