#314 closed defect (fixed)
psMetadataIteratorAlloc and Mutable parameter
| Reported by: | Owned by: | eugene | |
|---|---|---|---|
| Priority: | high | Milestone: | |
| Component: | PSLib SDRS | Version: | unspecified |
| Severity: | critical | Keywords: | |
| Cc: |
Description
Since psMetadata is formed from a psList and psHash containing duplicate set of
references of psMetadataItem objects, making a mutable iterator over just the
psList seems to be very dangerous as it opens up a reasonable means to add
something to the psList and not the psHash. I suggest that mutable be dropped
from the psMetadataIteratorAlloc parameter list and the return psListIterator
be set to be not mutable.
psListIterator* psMetadataIteratorAlloc(psMetadata* md, psS32 location)
{
if (md == NULL) {
return NULL;
}
return psListIteratorAlloc(md->list,location,false);
}
-rdd
Change History (4)
comment:1 by , 21 years ago
| Owner: | changed from to |
|---|
comment:2 by , 21 years ago
comment:4 by , 21 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Bug 315 negates this, as it defines a new prototype for psMetadataIteratorAlloc.

additionally, see bug 315 comments.