Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(330)

Unified Diff: third_party/qcms/src/chain.c

Issue 2815303003: [qcms] Disable advisory asserts when running in libfuzzer (Closed)
Patch Set: Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/qcms/README.chromium ('k') | third_party/qcms/src/iccread.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/qcms/src/chain.c
diff --git a/third_party/qcms/src/chain.c b/third_party/qcms/src/chain.c
index 525507084b54596dc0dff6a14e6c2f61e223caa6..46143cc754e64de5eb4fb5f72436240d65ae5f2d 100644
--- a/third_party/qcms/src/chain.c
+++ b/third_party/qcms/src/chain.c
@@ -29,6 +29,12 @@
#include "transform_util.h"
#include "matrix.h"
+#ifdef USE_LIBFUZZER
+#define ASSERT(x)
+#else
+#define ASSERT(x) assert(x)
+#endif
+
static struct matrix build_lut_matrix(struct lutType *lut)
{
struct matrix result;
@@ -831,7 +837,7 @@ static struct qcms_modular_transform* qcms_modular_transform_create_output(qcms_
goto fail;
}
} else {
- assert(0 && "Unsupported output profile workflow.");
+ ASSERT(0 && "Unsupported output profile workflow.");
return NULL;
}
@@ -906,7 +912,7 @@ static struct qcms_modular_transform* qcms_modular_transform_create(qcms_profile
goto fail;
append_transform(rgb_to_pcs, &next_transform);
} else {
- assert(0 && "input color space not supported");
+ ASSERT(0 && "input color space not supported");
goto fail;
}
@@ -949,7 +955,7 @@ static struct qcms_modular_transform* qcms_modular_transform_create(qcms_profile
goto fail;
append_transform(pcs_to_rgb, &next_transform);
} else {
- assert(0 && "output color space not supported");
+ ASSERT(0 && "output color space not supported");
goto fail;
}
// Not Completed
« no previous file with comments | « third_party/qcms/README.chromium ('k') | third_party/qcms/src/iccread.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698