Version française
Home     About     Download     Resources     Contact us    
Browse thread
Finalization and object dependencies
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Stefan Monnier <monnier@i...>
Subject: Re: Finalization and object dependencies
> Usually, application code will gracefully close all cursors, and the
> table, but I want my library to be as safe as possible to use, and
> avoid random crashes or memory leaks.

I recommend to consider it an error if the table (and cursors) were not
properly closed.  So instead of hiding the error (by silently closing tables
from finalizers), I recommend you signal an exception or at least log some
warning to stderr or syslog or something.


        Stefan