Subscribe

  • Subscribe  

Funny Goof up Using Adobe AIR

Posted by Sravan | April 17, 2009 .

Today I came across a post called AIR Deleted My Desktop posted by John C. Bland II on his blog. John added a new feature to his AIR app to save a file to a network share and was testing it against his desktop directory.

AIR cleaned the directory permanently. The copyTo function when copying a file A in directory D1 to a directory D2 which already has another file with the name A, first deletes D2/A and then copies D1/A to D2. When the from and to paths are the same, instead of returning an error message (or success) without any action, it goes ahead and deletes the D/A first and tries to copy the deleted file to itself which fails, of course.

John himself summed up why this is funny:

Nah, it wasn’t that big of a deal. It was more-so irritating that I wrote the code that did it. :)

The post is eight months old, and I hope the AIR team fixed the bug by now. Nevertheless it is interesting. Rather than using exceptions, I think first one could get a read-lock on file A and then proceed.

Leave a Comment

If you would like to make a comment, please fill out the form below.


Name

Email

Website

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word

Comments

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word


Related Posts

2 Comments so far
  1. John C. Bland II  April 18, 2009 7:13 pm

    lol. Yeah, that was quite funny after the fact. 😀

  2. Sravan  April 20, 2009 7:43 am

    :)

<

Error. Page cannot be displayed. Please contact your service provider for more details. (5)


Direct TV Offers - usdirect has the best directtv deals