<AWT Dev> RFR: [12] JDK-8196681: Java Access Bridge logging and debug flags dynamically controlled

Krishna Addepalli krishna.addepalli at oracle.com
Mon Dec 10 14:38:47 UTC 2018


Hi Sergey,

The only way to avoid changes to make file is by using C string manipulation API. 
Here is the webrev: http://cr.openjdk.java.net/~kaddepalli/8196681/webrev08 , although I would personally prefer using the C++ api.

Thanks,
Krishna

-----Original Message-----
From: Krishna Addepalli 
Sent: Friday, December 7, 2018 12:41 PM
To: Sergey Bylokhov <sergey.bylokhov at oracle.com>; Shashidhara Veerabhadraiah <shashidhara.veerabhadraiah at oracle.com>
Cc: Prasanta Sadhukhan <prasanta.sadhukhan at oracle.com>; awt-dev at openjdk.java.net
Subject: RE: <AWT Dev> RFR: [12] JDK-8196681: Java Access Bridge logging and debug flags dynamically controlled

Hi Sergey,

I checked the code with only /EHs - which says: "The exception-handling model that catches synchronous (C++) exceptions only and tells the compiler to assume that functions declared as extern "C" may throw an exception."
With this, our code compiles, so here is the modified webrev: http://cr.openjdk.java.net/~kaddepalli/8196681/webrev07

Thanks,
Krishna
-----Original Message-----
From: Sergey Bylokhov 
Sent: Thursday, December 6, 2018 11:37 PM
To: Krishna Addepalli <krishna.addepalli at oracle.com>; Shashidhara Veerabhadraiah <shashidhara.veerabhadraiah at oracle.com>
Cc: Prasanta Sadhukhan <prasanta.sadhukhan at oracle.com>; awt-dev at openjdk.java.net
Subject: Re: <AWT Dev> RFR: [12] JDK-8196681: Java Access Bridge logging and debug flags dynamically controlled

> Since I added string.h and its related code for manipulating the path, I encountered this warning. The standard way to deal with this is to specify /EHsc, which is to enable catching of asynchronous exceptions.
> 
> https://docs.microsoft.com/en-us/previous-versions/1deeycx5(v=vs.140)

And my text from the previous email was copied from this link.
"tells the compiler to assume that functions declared as extern "C" never throw a C++ exception."
I am not sure that this is correct assumption, because the new code actually may throw an exception.

> -----Original Message-----
> From: Sergey Bylokhov
> Sent: Thursday, December 6, 2018 10:49 PM
> To: Krishna Addepalli <krishna.addepalli at oracle.com>; Shashidhara Veerabhadraiah <shashidhara.veerabhadraiah at oracle.com>
> Cc: Prasanta Sadhukhan <prasanta.sadhukhan at oracle.com>; awt-dev at openjdk.java.net
> Subject: Re: <AWT Dev> RFR: [12] JDK-8196681: Java Access Bridge logging and debug flags dynamically controlled
> 
> On 06/12/2018 01:10, Krishna Addepalli wrote:
>> Hi Sergey,
>>
>> I got this error while compiling: warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify /EHsc.
>> I couldn't immediately figure out how to specify that option, so I disabled that warning (4530).
>> Now I corrected this as well as making the filePath a local variable.
>> Here is the updated webrev:
>> http://cr.openjdk.java.net/~kaddepalli/8196681/webrev06
> 
> But what new code required this option? As far as I understand part of this option is to "tells the compiler to assume that functions declared as extern "C" never throw a C++ exception."
> I am not sure that this is correct assumption, is it?
> 
> 
> --
> Best regards, Sergey.
> 


-- 
Best regards, Sergey.


More information about the awt-dev mailing list