Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #16092
| Path | csiph.com!usenet.pasdenom.info!news.albasani.net!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Daniele Futtorovic <da.futt.news@laposte-dot-net.invalid> |
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: throw null investigation |
| Date | Thu, 19 Jul 2012 00:06:57 +0200 |
| Organization | A noiseless patient Spider |
| Lines | 22 |
| Message-ID | <ju7c31$p8e$1@dont-email.me> (permalink) |
| References | <a8e60469-b392-4a98-b845-42caa79f7959@googlegroups.com> <GhENr.7926$jA7.4844@newsfe15.iad> <ju76n5$pcv$1@dont-email.me> <ju7a51$d92$1@dont-email.me> <ju7amv$hfv$1@dont-email.me> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=ISO-8859-1 |
| Content-Transfer-Encoding | 7bit |
| Injection-Date | Wed, 18 Jul 2012 22:07:29 +0000 (UTC) |
| Injection-Info | mx04.eternal-september.org; posting-host="af443352c696022ce926c3d891feba1d"; logging-data="25870"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/dTDg2Kj8QnypyI/wywq79" |
| User-Agent | Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2.28) Gecko/20120306 Thunderbird/3.1.20 |
| In-Reply-To | <ju7amv$hfv$1@dont-email.me> |
| Cancel-Lock | sha1:XWc/4coeZBv0TlZmyGgGZaVwtq8= |
| Xref | csiph.com comp.lang.java.programmer:16092 |
Show key headers only | View raw
On 18/07/2012 23:43, markspace allegedly wrote: > On 7/18/2012 2:33 PM, Daniele Futtorovic wrote: > >> But if the JNI code actually wanted to throw an NPE, and teh Jav wraps a >> null into an NPE, wouldn't it actually be more efficient if the JNI code >> "threw" a null? > > > That's what I'm saying. I think perhaps Java does NOT wrap a null > exception thrown by JNI code. Java wraps a null value when you throw it > from Java, but JNI tends to have a lot of holes, especially if you are > dealing with "signed" or "trusted" code. There's ways to get around the > checks Java does of JNI code in the interest of speed, and if you don't > check, then you don't get protection. But if what you say is correct, and Java does /not/ systematically wrap nulls "thrown" from JNI (assuming it's possible), then it would be technically possible to catch a null Exception in the Java runtime, wouldn't it? -- DF.
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
throw null investigation bob smith <bob@coolfone.comze.com> - 2012-07-18 10:10 -0700
Re: throw null investigation Daniel Pitts <newsgroup.nospam@virtualinfinity.net> - 2012-07-18 12:39 -0700
Re: throw null investigation markspace <-@.> - 2012-07-18 13:35 -0700
Re: throw null investigation Daniele Futtorovic <da.futt.news@laposte-dot-net.invalid> - 2012-07-18 23:33 +0200
Re: throw null investigation markspace <-@.> - 2012-07-18 14:43 -0700
Re: throw null investigation Daniele Futtorovic <da.futt.news@laposte-dot-net.invalid> - 2012-07-19 00:06 +0200
Re: throw null investigation markspace <-@.> - 2012-07-18 15:55 -0700
Re: throw null investigation Daniel Pitts <newsgroup.nospam@virtualinfinity.net> - 2012-07-18 16:00 -0700
Re: throw null investigation Daniel Pitts <newsgroup.nospam@virtualinfinity.net> - 2012-07-18 16:16 -0700
Re: throw null investigation Roedy Green <see_website@mindprod.com.invalid> - 2012-07-18 17:09 -0700
csiph-web