Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!feeder.erje.net!newsfeed.straub-nv.de!texta.sil.at!newscore.univie.ac.at!aconews-feed.univie.ac.at!aconews.univie.ac.at!not-for-mail Newsgroups: comp.lang.java.programmer From: Andreas Leitgeb Subject: Re: Trying to Understand Purpose of a Catch Block for IOException in the Presence of One for FileNotFound References: <0f7fb5c4-6031-4778-9ef7-de757bbdda39@m5g2000prh.googlegroups.com> Reply-To: avl@logic.at User-Agent: slrn/pre0.9.9-111 (Linux) Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: Date: 12 Aug 2011 19:35:24 GMT Lines: 18 NNTP-Posting-Host: gamma.logic.tuwien.ac.at X-Trace: 1313177724 tunews.univie.ac.at 71616 128.130.175.3 X-Complaints-To: abuse@tuwien.ac.at Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:7055 KevinSimonson wrote: > I've actually written a number of different programs trying to find > something that I can run that will throw an exception that is a > but not a . Just speculating: have you tried to read a large file from an USB thumbdrive and midway disconnect the drive? Warning: that *may* damage the thumbdrive (even physically, not just the filesystem on it!), so use an old small one that you wont miss in case it's really broken afterwards. > I've opened a file for input, done a "chmod u-r " > while the program's running, ... Removing permissions after the file has been opened doesn't ever matter, anyway. Permissions are only checked at open().