diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2011-10-11 13:49:36 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2011-10-11 13:49:36 +0100 |
commit | 88a1b83177ecaf044a3425abc8faa571ca2b41f5 (patch) | |
tree | f1eab772ed235de6d56f30c005ddb9d7394f7652 | |
parent | c8bfa8c0888b16747c5e07ca4b844d5feabd8756 (diff) |
observer: Fix typo and handle the condition of no script device
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r-- | src/cairo-surface-observer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cairo-surface-observer.c b/src/cairo-surface-observer.c index 22909e13..ebb38b98 100644 --- a/src/cairo-surface-observer.c +++ b/src/cairo-surface-observer.c @@ -1774,7 +1774,7 @@ replay_record (cairo_observation_t *log, cairo_surface_t *surface; cairo_int_status_t status; - if (log->record == NULL) + if (log->record == NULL || script == NULL) return FALSE; surface = cairo_script_surface_create (script, @@ -1814,7 +1814,7 @@ _cairo_observation_print (cairo_output_stream_t *stream, cairo_device_t *script; cairo_time_t total; -#if CAIRO_HAS_SCRIPT_SURFAC +#if CAIRO_HAS_SCRIPT_SURFACE script = _cairo_script_context_create_internal (stream); _cairo_script_context_attach_snapshots (script, FALSE); #else |