diff options
| author | bulia byak <buliabyak@gmail.com> | 2007-02-24 17:55:20 +0000 |
|---|---|---|
| committer | buliabyak <buliabyak@users.sourceforge.net> | 2007-02-24 17:55:20 +0000 |
| commit | 3c604e26b26ba333b4ff5090e9d5108699ede6bc (patch) | |
| tree | 69913abf38fc816e8b9415447f2f1caa248031ec /src/dialogs/clonetiler.cpp | |
| parent | fix crash when tracing with too small clones (diff) | |
| download | inkscape-3c604e26b26ba333b4ff5090e9d5108699ede6bc.tar.gz inkscape-3c604e26b26ba333b4ff5090e9d5108699ede6bc.zip | |
fix crash when tracing with too small clones
(bzr r2423)
Diffstat (limited to 'src/dialogs/clonetiler.cpp')
| -rw-r--r-- | src/dialogs/clonetiler.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/dialogs/clonetiler.cpp b/src/dialogs/clonetiler.cpp index e063c8054..130480608 100644 --- a/src/dialogs/clonetiler.cpp +++ b/src/dialogs/clonetiler.cpp @@ -786,12 +786,13 @@ clonetiler_trace_pick (NR::Rect box) /* Set up pixblock */ guchar *px = g_new(guchar, 4 * width * height); - memset(px, 0x00, 4 * width * height); if (px == NULL) { return 0; // buffer is too big or too small, cannot pick, so return 0 } + memset(px, 0x00, 4 * width * height); + /* Render */ NRPixBlock pb; nr_pixblock_setup_extern( &pb, NR_PIXBLOCK_MODE_R8G8B8A8N, |
