diff options
Diffstat (limited to 'src/object/sp-image.cpp')
| -rw-r--r-- | src/object/sp-image.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/object/sp-image.cpp b/src/object/sp-image.cpp index f3be15b53..45016bd45 100644 --- a/src/object/sp-image.cpp +++ b/src/object/sp-image.cpp @@ -414,6 +414,12 @@ void SPImage::update(SPCtx *ctx, unsigned int flags) { // TODO: eliminate ox, oy, sx, sy sp_image_update_canvas_image ((SPImage *) this); + + // don't crash with missing xlink:href attribute + if (!this->pixbuf) { + return; + } + double proportion_pixbuf = this->pixbuf->height() / (double)this->pixbuf->width(); double proportion_image = this->height.computed / (double)this->width.computed; if (this->prev_width && |
