diff options
Diffstat (limited to 'include/linux/fb.h')
-rw-r--r-- | include/linux/fb.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/fb.h b/include/linux/fb.h index 8e5a9dfb76b..e7445df44d6 100644 --- a/include/linux/fb.h +++ b/include/linux/fb.h @@ -873,6 +873,8 @@ struct fb_info { static inline struct apertures_struct *alloc_apertures(unsigned int max_num) { struct apertures_struct *a = kzalloc(sizeof(struct apertures_struct) + max_num * sizeof(struct aperture), GFP_KERNEL); + if (!a) + return NULL; a->count = max_num; return a; } |