19 lines
686 B
Diff
19 lines
686 B
Diff
|
--- devices/vector/gdevpdts.c.orig 2018-03-21 09:48:06.000000000 +0100
|
||
|
+++ devices/vector/gdevpdts.c 2018-06-05 14:39:39.000000000 +0200
|
||
|
@@ -103,9 +103,14 @@ append_text_move(pdf_text_state_t *pts,
|
||
|
static int
|
||
|
set_text_distance(gs_point *pdist, double dx, double dy, const gs_matrix *pmat)
|
||
|
{
|
||
|
- int code = gs_distance_transform_inverse(dx, dy, pmat, pdist);
|
||
|
+ int code;
|
||
|
double rounded;
|
||
|
|
||
|
+ if (dx > 1e38 || dy > 1e38)
|
||
|
+ code = gs_error_undefinedresult;
|
||
|
+ else
|
||
|
+ code = gs_distance_transform_inverse(dx, dy, pmat, pdist);
|
||
|
+
|
||
|
if (code == gs_error_undefinedresult) {
|
||
|
/* The CTM is degenerate.
|
||
|
Can't know the distance in user space.
|