[gnome-web-photo/webkit] Enforce the cairo limit everywhere



commit 3295f8b96456f9f69745d66966b906aeae75334e
Author: Vincent Untz <vuntz gnome org>
Date:   Wed Feb 16 12:15:43 2011 +0100

    Enforce the cairo limit everywhere

 src/gnome-web-photo.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/gnome-web-photo.c b/src/gnome-web-photo.c
index 53c9ef5..9152d81 100644
--- a/src/gnome-web-photo.c
+++ b/src/gnome-web-photo.c
@@ -841,6 +841,8 @@ main (int    argc,
     return 1;
   }
 
+  g_assert (data.thumbnail_size < MAX_SIZE);
+
   /* Check width */
   if (data.width < MIN_WIDTH || data.width > MAX_WIDTH) {
     g_printerr (_("--width out of bounds; must be between %d and %d!\n"), MIN_WIDTH, MAX_WIDTH);
@@ -852,6 +854,8 @@ main (int    argc,
     return 1;
   }
 
+  g_assert (data.width < MAX_SIZE);
+
   /* Check --print-background */
   if (data.mode != MODE_PRINT && data.print_background) {
     g_printerr (_("--print-background is only available in print mode!\n"));



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]