Closed Bug 14324 Opened 21 years ago Closed 21 years ago

[MIGRATION] need to use new SMTP API

Categories

(MailNews Core :: Backend, defect, P3)

x86
Linux
defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: alecf, Assigned: sspitzer)

Details

The new SMTP API is complete, please use the new SMTP API to migrate profiles
from 4.x

from C++, you should get the SMTP service, then call GetDefaultServer() to get
the server (an nsISmtpServer), then call SetHostname and SetUsername as
appropriate.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
fixed!

you have to re-run -installer to try it.
Target Milestone: M11
QA Contact: lchiang → ppandit
The following code was in nsMessengerMigrator.cpp. Looks like the suggestion 
Alec made so marking as VERIFIED.

624     rv = smtpService->GetDefaultServer(getter_AddRefs(smtpServer));
625     if (NS_FAILED(rv)) return rv;    
626 
627     rv = MigrateSmtpServer(smtpServer);
628     if (NS_FAILED(rv)) return rv;    

nsMessengerMigrator::MigrateSmtpServer(nsISmtpServer *server)
696 {
697   
MIGRATE_SIMPLE_STR_PREF(PREF_4X_NETWORK_HOSTS_SMTP_SERVER,server,SetHostname)
698   MIGRATE_SIMPLE_STR_PREF(PREF_4X_MAIL_SMTP_NAME,server,SetUsername)
699   return NS_OK;
700 }

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