Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8127504

Gtk: [Linux] fatal error on using clipboard with custom data format

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 7u6
    • fx2.1
    • javafx
    • 2.1.0b16, JRE 7.0-b146

      Run attached code:

      import java.util.HashMap;
      import java.util.Map;
      import javafx.application.Application;
      import javafx.scene.input.Clipboard;
      import javafx.scene.input.ClipboardContent;
      import javafx.scene.input.DataFormat;
      import javafx.stage.Stage;

      public class DnD extends Application {

          final static Map<DataFormat, Object> receivedContent = new HashMap<DataFormat, Object>();

          @Override
          public void start(Stage stage) {
              ClipboardContent content = new ClipboardContent();
              DataFormat DF_CUSTOM_STRING = new DataFormat("dndwithcontrols.custom.string");
              String CONTENT_CUSTOM_STRING = "Hello Custom String!";
              content.put(DF_CUSTOM_STRING, CONTENT_CUSTOM_STRING);
              Clipboard.getSystemClipboard().setContent(content);
              receivedContent.put(DF_CUSTOM_STRING, Clipboard.getSystemClipboard().getContent(DF_CUSTOM_STRING));
              //String s = (String) Clipboard.getSystemClipboard().getContent(DF_CUSTOM_STRING);
          }

          public static void main(String[] args) {
              Application.launch(args);
          }
      }

      I see fatal error:
      # A fatal error has been detected by the Java Runtime Environment:
      #
      # SIGSEGV (0xb) at pc=0xb6f36f0c, pid=13992, tid=2099002224
      #
      # JRE version: 7.0-b146
      # Java VM: OpenJDK Server VM (21.0-b16 mixed mode linux-x86 )
      # Problematic frame:
      # V [libjvm.so+0x3f1f0c] jni_IsInstanceOf+0x8c
      #
      # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
      #
      # An error report file with more information is saved as:
      # /home/fx/NetBeansProjects/CoordinatesIssue/hs_err_pid13992.log
      #
      # If you would like to submit a bug report, please visit:
      # http://bugreport.sun.com/bugreport/crash.jsp
      #
      Java Result: 134

      Not reproducible with jdk6. And reproducible with JDK7.

            msladecek Martin Sládeček
            akirov Alexander Kirov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: