octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

proposal: avoid potential leakage in src/ov-base-mat.h


From: John W. Eaton
Subject: proposal: avoid potential leakage in src/ov-base-mat.h
Date: Sat, 22 Jan 2011 02:56:12 -0500

On 21-Jan-2011, CdeMills wrote:

| introducing an operator= in octave_base_matrix to avoid potential leakage.
| Indeed, the memory pointed by typ and idx_cache should be released before
| being assigned another value. 

I agree that it would be better to prevent a potential leak.  But I
think that assigning an octave_base_matrix object would be a misuse of
the class, so it would be better to prevent that than to allow
assignment.  If you'd like, submit a patch that enforces this by
adding private assignment operators to these classes.

jwe


reply via email to

[Prev in Thread] Current Thread [Next in Thread]