--- old/src/java.base/macosx/native/libjava/java_props_macosx.c 2019-05-02 12:31:43.918896210 -0700 +++ new/src/java.base/macosx/native/libjava/java_props_macosx.c 2019-05-02 12:31:43.798896212 -0700 @@ -212,25 +212,6 @@ } } -int isInAquaSession() { - // environment variable to bypass the aqua session check - char *ev = getenv("AWT_FORCE_HEADFUL"); - if (ev && (strncasecmp(ev, "true", 4) == 0)) { - // if "true" then tell the caller we're in an Aqua session without actually checking - return 1; - } - // Is the WindowServer available? - SecuritySessionId session_id; - SessionAttributeBits session_info; - OSStatus status = SessionGetInfo(callerSecuritySession, &session_id, &session_info); - if (status == noErr) { - if (session_info & sessionHasGraphicAccess) { - return 1; - } - } - return 0; -} - // 10.9 SDK does not include the NSOperatingSystemVersion struct. // For now, create our own typedef struct {