Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic DOORS (steve huntington)
Decrease font size
Increase font size
Topic Title: EXCEPTION_ACCESS_VIOLATION
Topic Summary: Exception being thrown by "for stdObj in current Module do"
Created On: 22-Jan-2009 16:43
Status: Post and Reply
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Quick Reply Quick Reply
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
Answer This question was answered by Nikkia Carter, on Friday, January 30, 2009 10:33 PM

Answer:
Ron,

Thanks! I will try that.

Peace and Blessings,
Nikki

Louie - thanks for your comments as well.
 22-Jan-2009 16:43
User is offline View Users Profile Print this message


Nikkia Carter

Posts: 18
Joined: 26-Feb-2008

Hey! I'm getting the following error when running my script:

line 141: for stdObj in current Module do
An unexpected error has occured: doors.exe caused an EXCEPTION_ACCESS_VIOLATION in door.exe at 001B:004B 79A6

Then the Dignostic Log appears. The script goes through a module which contains the path of other modules. It goes to those other modules and see if it has a certian attribute. If it doesn't then a message is printed that that specific module doesn't have the attribute. It work fine on a smaller list of modules but on the all inclusive list (which is about twice or more as long) but gets part way through and throws the exception. The point where it breaks is different almost each time which leads me to believe that it is running out of memory and that is causing the exception to be thrown at diffewrent points in its processing. Anybody have a similar situation? Anyway to fix it? Thanks!

Peace and Blessings,
Nikki
Report this to a Moderator Report this to a Moderator
 23-Jan-2009 12:33
User is offline View Users Profile Print this message


Tony Goodman

Posts: 97
Joined: 6-May-2008

Loop through your objects and shove the module names into a skip list.

Then loop through the skip list to open modules.

remember to close each module after you have finished with it.

Check that the module names are correct before attempting to open the module.
You can do this using bool module(string name).

Make sure that the module containing the names does not contain its own name!

-------------------------
Tony Goodman
Smart DXL limited
www.smartdxl.com
Report this to a Moderator Report this to a Moderator
 23-Jan-2009 20:12
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

The 'current' module changes often when you open other modules. I'd say it changes 'irratically' because I haven't done the work to narrow down exactly when the current module changes (and I suspect it changes differently now than it doe back in v6 days).

Anyway, your loop has a major flaw, using 'current Module'. If the current module changes inside the loop, such as when opening another module, then when the loop gets back to the top the whole thing is messed up. That's like "For every passenger in My car" and then inside the loop selling the car and buying a new one; what does it mean to try to get the NEXT passenger in the NEW car? Instead use "For every passenger in the Toyota".

Use: [Module mCurr = current; for obj in mCurr do{...}].

- Louie

Aaaahhhh. SW engineers will recall the axium "Don't modify the loop variable inside the loop". No duh.
Report this to a Moderator Report this to a Moderator
 23-Jan-2009 21:09
User is offline View Users Profile Print this message


Nikkia Carter

Posts: 18
Joined: 26-Feb-2008

Thanks, Tony!

All that you suggested is already being done. Is it possible that memory is just running out because of the size of the list? I don't get the exception on a smaller subset of the list.

Peace and Blessings,
Nikki
Report this to a Moderator Report this to a Moderator
 23-Jan-2009 22:58
User is offline View Users Profile Print this message


ron lewis

Posts: 650
Joined: 20-Sep-2004

Nikkia, I have a question for you. Is there any reason that you keep a module open after processing? Try closing modules when you don't need the module open any longer, then memory problem isn't as big of an issue.
Report this to a Moderator Report this to a Moderator
 27-Jan-2009 17:03
User is offline View Users Profile Print this message


Nikkia Carter

Posts: 18
Joined: 26-Feb-2008

Ron,

Each module is being closed after use. I think it has to do with the pure size of the list and that a stmt was printed after each module was processed. I just figured out yesterday that the violation doesn't occur when the print stmt is taken off for the same size list.

Peace and Blessings,
Nikki
Report this to a Moderator Report this to a Moderator
 27-Jan-2009 17:13
User is offline View Users Profile Print this message


ron lewis

Posts: 650
Joined: 20-Sep-2004

Suggest get rid of print statement and write output to a file which you can process at a later time.

Also, use buffers instead of strings to minimize use of memory.
Report this to a Moderator Report this to a Moderator
 27-Jan-2009 17:39
User is offline View Users Profile Print this message


Nikkia Carter

Posts: 18
Joined: 26-Feb-2008

Answer Answer
Ron,

Thanks! I will try that.

Peace and Blessings,
Nikki

Louie - thanks for your comments as well.
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 1 users logged in.
The most users ever online was 15 on 15-Jan-2009 at 16:36.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.