#1 Burning Software

It is currently Sat Apr 27, 2024 6:56 pm

All times are UTC




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: DataBurner: Crash on Abort
PostPosted: Thu Jul 02, 2009 2:21 pm 
Offline

Joined: Mon Aug 25, 2008 1:50 pm
Posts: 394
Hello Support,

I am using StarBurnX dated 10 May 09.
1) I am using DataBurner class to burn data on DVD +RW.
2) I was testing my sample application. On aborting data burning, I got an unhandled exception, which is coming in my Studio Solution also, I have attached an image of that with this post.
3) I think I doing something wrong but couldn't figure that out. In StarburnX sample this is not happening for the same scenario.
4) I have spent a long time to figure out what went wrong, but didn't got the reason.
5) Will you help me please? I am attaching a Debug log with this post.
Thank you very much for your help.


Attachments:
StarBurn.rar [3.99 KiB]
Downloaded 486 times
Crash.jpg
Crash.jpg [ 12.56 KiB | Viewed 7224 times ]
Top
 Profile  
 
 Post subject: Re: DataBurner: Crash on Abort
PostPosted: Wed Jul 08, 2009 10:39 am 
Offline

Joined: Thu Dec 13, 2007 8:44 am
Posts: 609
Hello,

Hmm ... the SDK function StarBurn_ISO9660JolietFileTree_Cancel was not called it means that burning was not really canceled!

Which programming language do you use?

Regards,

Dmitry


Top
 Profile  
 
 Post subject: Re: DataBurner: Crash on Abort
PostPosted: Thu Jul 09, 2009 9:28 am 
Offline

Joined: Mon Aug 25, 2008 1:50 pm
Posts: 394
Hello Dima Sir,

1) I am using StarBurnX and developing my sample program in VB.NET.
2) I am getting this crash on aborting data burning process.
3) I am calling abort function when user clicks on abort button, in which I am calling dataBurner.Locktray = False and then dataBurner.Cancel in separate thread (As advised in StarBurnX help).
5) After this I am immediately calling eject drive (To refresh information of the drive).
6) And after that I am calling DataBurner.Files.Clear() (To clear previously added data) and to avoid the problem IMAGE_TREE_ALREADY_BUILT while adding data again.
7) I think I am getting crash because aborting is done in thread and until this process is complete I am calling DataBurner.Files.Clear().
8) But as I am not able to know when the abort process is finished. This problem is coming.
9) Is it possible to include an event callback which will notify us that abort process is complete because abort process may takes a bit time. As this is an IO process, so it is hardware dependent and obviously may take time.
10) It would be better if any event will notify us aborting is complete.
11) Is the problem clear to you?


Top
 Profile  
 
 Post subject: Re: DataBurner: Crash on Abort
PostPosted: Fri Jul 10, 2009 6:26 am 
Offline

Joined: Thu Dec 13, 2007 8:44 am
Posts: 609
Hello,

1) The main thread can wait till the "Burning" thread is not finished using the WaitForSingleObject for example. After ( the "Burning" thread is really finished ) you may eject tray, clear files etc.

2) You may call the Cancel from separated thread also. In this case you should create a new thread and
- call the DataBurner.Cancel
- set the status current operation
later, when the Burn operation will be really finished you may post message from the "Burning" thread to the main thread.

!!! Do not call the DataBurner.Files.Clear(), Eject etc. in the "Canceling" thread !!!!

Is my explanations are clear ? :)

Regards,

Dmitry


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 21 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group