Memory leaks with Photoshop's Javascript

[size=2]Looking at the Photoshop javascript tutorials, I noticed that the author makes a point of assigning the variables back to null, after being done with them.

I have been working on a script similar to the yearbook example.

I have quite a few pages to process, and photoshop seems to get bogged down half-way through, due to memory issues, I believe. There is nothing wrong with the data.
I am not nullifying the variables, at the moment, since I assume that if they are defined within an expression or a function, they get nullified automatically.

I am suspecting that there may be some memory leaks in Photoshop CS2’s implementation of Javascript.

My question is: should I take the extra step of specifically nullifying all my variables after I am done with them (even though I shouldn’t have to)?

Did anyone run into similar problems?

[/size]