[babl] Allow up to (and including) BABL_MAX_COMPONENTS
- From: Mukund Sivaraman <muks src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [babl] Allow up to (and including) BABL_MAX_COMPONENTS
- Date: Thu, 26 Feb 2015 15:08:02 +0000 (UTC)
commit 4555d43cbf95863bad80598b4c3be735858a560f
Author: Mukund Sivaraman <muks banu com>
Date: Thu Feb 26 20:21:18 2015 +0530
Allow up to (and including) BABL_MAX_COMPONENTS
babl/babl-model.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
---
diff --git a/babl/babl-model.c b/babl/babl-model.c
index 91c57ee..fec5209 100644
--- a/babl/babl-model.c
+++ b/babl/babl-model.c
@@ -118,14 +118,12 @@ babl_model_new (void *first_argument,
switch (bablc->class_type)
{
case BABL_COMPONENT:
- component [components] = (BablComponent *) bablc;
- components++;
-
if (components >= BABL_MAX_COMPONENTS)
{
babl_log ("maximum number of components (%i) exceeded for %s",
BABL_MAX_COMPONENTS, assigned_name);
}
+ component [components++] = (BablComponent *) bablc;
break;
case BABL_MODEL:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]