From c35d92c682d8b514de495715b12054bfae92f805 Mon Sep 17 00:00:00 2001
From: stepan <stepan.sindelar@oracle.com>
Date: Fri, 9 Jun 2017 19:16:53 +0200
Subject: [PATCH] FastR Grid: fix savePlot function.

---
 .../truffle/r/library/fastrGrid/device/awt/Graphics2DDevice.java | 1 +
 1 file changed, 1 insertion(+)

diff --git a/com.oracle.truffle.r.library/src/com/oracle/truffle/r/library/fastrGrid/device/awt/Graphics2DDevice.java b/com.oracle.truffle.r.library/src/com/oracle/truffle/r/library/fastrGrid/device/awt/Graphics2DDevice.java
index 90bf1adc20..e29477b675 100644
--- a/com.oracle.truffle.r.library/src/com/oracle/truffle/r/library/fastrGrid/device/awt/Graphics2DDevice.java
+++ b/com.oracle.truffle.r.library/src/com/oracle/truffle/r/library/fastrGrid/device/awt/Graphics2DDevice.java
@@ -182,6 +182,7 @@ public class Graphics2DDevice implements GridDevice {
     void setGraphics2D(Graphics2D newGraphics) {
         assert newGraphics != null;
         graphics = newGraphics;
+        cachedContext = null;
     }
 
     public Graphics2D getGraphics2D() {
-- 
GitLab