[mutter] screen: Allow NULL out arguments in meta_screen_get_size
- From: Tomeu Vizoso <tomeuv src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] screen: Allow NULL out arguments in meta_screen_get_size
- Date: Wed, 5 Sep 2012 14:41:23 +0000 (UTC)
commit 079822c3f45488fd75e832a627e68a5989978556
Author: Tomeu Vizoso <tomeu vizoso collabora com>
Date: Wed Aug 29 19:34:30 2012 +0200
screen: Allow NULL out arguments in meta_screen_get_size
src/core/screen.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/core/screen.c b/src/core/screen.c
index ea582b5..db9b5ed 100644
--- a/src/core/screen.c
+++ b/src/core/screen.c
@@ -3411,8 +3411,11 @@ meta_screen_get_size (MetaScreen *screen,
int *width,
int *height)
{
- *width = screen->rect.width;
- *height = screen->rect.height;
+ if (width != NULL)
+ *width = screen->rect.width;
+
+ if (height != NULL)
+ *height = screen->rect.height;
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]