[gegl] operations/external/raw-load: Be more assertive about what we expect
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] operations/external/raw-load: Be more assertive about what we expect
- Date: Sat, 4 Feb 2017 18:44:10 +0000 (UTC)
commit c518ad0fb7ce70b00a5f74a916f000db83bcfa48
Author: Debarshi Ray <debarshir gnome org>
Date: Sat Feb 4 02:13:19 2017 +0100
operations/external/raw-load: Be more assertive about what we expect
Unless there is a programmer error, there is no reason for the
libraw_processed_image_t (ie. p->image) to be anything other than NULL
when the libraw_data_t (ie. p->LibRaw) is NULL. Therefore let's assert
it because an assignment might mask a potential bug.
https://bugzilla.gnome.org/show_bug.cgi?id=778160
operations/external/raw-load.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/operations/external/raw-load.c b/operations/external/raw-load.c
index d2fb095..d2c739a 100644
--- a/operations/external/raw-load.c
+++ b/operations/external/raw-load.c
@@ -90,7 +90,7 @@ prepare (GeglOperation *operation)
if (p->LibRaw == NULL)
{
- p->image = NULL;
+ g_return_if_fail (p->image == NULL);
if ((p->LibRaw = libraw_init(LIBRAW_OPTIONS_NONE)) == NULL)
g_warning ("raw-load: Error Initializing raw library");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]