Closed Bug 17147 Opened 25 years ago Closed 25 years ago

AddListeners mishandles case where Listenener already exists.

Categories

(MailNews Core :: Composition, defect, P3)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: bratell, Assigned: rhp)

Details

A new listener is not added when adding a listener to a service already having a
listener in
nsMsgComposeAndSend::AddListener in /mozilla/mailnews/compose/src/nsMsgSend.cpp
and
nsMsgSendLater::AddListener in /mozilla/mailnews/compose/src/nsMsgSendLater.cpp

I think
    mListenerArrayCount = 1;
should be changed to
    mListenerArrayCount += 1;

and before
    return NS_OK;
should be
    mListenerArray[mListenerArrayCount-1] = aListener;
Status: NEW → ASSIGNED
Target Milestone: M11
Good catch...already fixed in my tree and I will checkin this Monday.

- rhp
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
I fixed this...deals with the listeners properly.

- rhp
QA Contact: lchiang → ppandit
Rich - can you point me to which revision numbers the changes were made in. I
can't find the exact changes you made regarding this bug.

Thanks,
Par
I'm really not sure on the CVS changes...had a problem finding them myself but
I sight checked the code and the changes are there.

- rhp
Status: RESOLVED → VERIFIED
based on what rhp says - VERIFIED
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.