Closed Bug 694500 Opened 13 years ago Closed 13 years ago

crash CCompositionFile::EnsureHasDataInBuffer

Categories

(MailNews Core :: Import, defect)

x86
Windows Vista
defect
Not set
critical

Tracking

(thunderbird8 fixed, thunderbird9 fixed)

RESOLVED FIXED
Thunderbird 10.0
Tracking Status
thunderbird8 --- fixed
thunderbird9 --- fixed

People

(Reporter: m_kato, Assigned: m_kato)

Details

(Keywords: crash)

Crash Data

Attachments

(1 file)

- m_fileSize should be initialized to 0 at first
- operator bool() should check m_pInputStream too

This bug was filed from the Socorro interface and is 
report bp-2ca55d94-35d0-475f-83e0-3bed02111011 .
============================================================= 
0 	xul.dll 	CCompositionFile::EnsureHasDataInBuffer 	mailnews/import/outlook/src/nsOutlookCompose.cpp:791
1 	xul.dll 	CCompositionFile::ToDest<dest_nsCString> 	mailnews/import/outlook/src/nsOutlookCompose.cpp:875
2 	xul.dll 	CCompositionFile::ToString 	mailnews/import/outlook/src/nsOutlookCompose.cpp:918
3 	xul.dll 	nsOutlookCompose::CopyComposedMessage 	mailnews/import/outlook/src/nsOutlookCompose.cpp:523
4 	xul.dll 	nsOutlookCompose::ProcessMessage 	mailnews/import/outlook/src/nsOutlookCompose.cpp:571
5 	xul.dll 	nsOutlookMail::ImportMessage 	mailnews/import/outlook/src/nsOutlookMail.cpp:475
6 	xul.dll 	nsOutlookMail::ImportMailbox 	mailnews/import/outlook/src/nsOutlookMail.cpp:441
7 	xul.dll 	ImportOutlookMailImpl::ImportMailbox 	mailnews/import/outlook/src/nsOutlookImport.cpp:470
8 	xul.dll 	ImportMailThread 	mailnews/import/src/nsImportMail.cpp:911
9 	nspr4.dll 	_PR_NativeRunThread 	nsprpub/pr/src/threads/combined/pruthr.c:426
10 	nspr4.dll 	pr_root 	nsprpub/pr/src/md/windows/w95thred.c:122
11 	mozcrt19.dll 	_callthreadstartex 	objdir-tb/mozilla/memory/jemalloc/crtsrc/threadex.c:348
12 	mozcrt19.dll 	_threadstartex 	objdir-tb/mozilla/memory/jemalloc/crtsrc/threadex.c:326
13 	kernel32.dll 	BaseThreadStart
might this be a regression ... because there are no crashes prior to version 6?


two crashes have interesting comments about antivirus

bp-fbb71ec0-7312-43b9-944b-4e9022110928 I was importing from Outlook, then AVG reported that an email had a virus

bp--7947-49c7-b918-4ce962111004 doing an outlook import and bitdefender is trapping a message with a virus.
Component: Migration → Import
Product: Thunderbird → MailNews Core
QA Contact: migration → import
(In reply to Wayne Mery (:wsmwk) from comment #1)
> might this be a regression ... because there are no crashes prior to version
> 6?

commit is the following.  commit message has no bug number...  

changeset:   7784:90c3929c5b5d
user:        David Bienvenu <bienvenu@nventure.com>
date:        Tue May 17 12:27:14 2011 -0700
summary:     Mike Kaganski <mikekaganski@gmail.com>
Assignee: nobody → m_kato
Attached patch fixSplinter Review
Attachment #567404 - Flags: review?(dbienvenu)
(In reply to Makoto Kato from comment #2)

thx for the patch!

> commit is the following.  commit message has no bug number...  
> 
> changeset:   7784:90c3929c5b5d
> user:        David Bienvenu <bienvenu@nventure.com>
> date:        Tue May 17 12:27:14 2011 -0700
> summary:     Mike Kaganski <mikekaganski@gmail.com>

Yes, I messed up the commit comment - it's bug 207156. Do you have a reproducible case for this bug, or did you come up with the fix by code inspection?
(In reply to David :Bienvenu from comment #4)
> (In reply to Makoto Kato from comment #2)
> 
> thx for the patch!
> 
> > commit is the following.  commit message has no bug number...  
> > 
> > changeset:   7784:90c3929c5b5d
> > user:        David Bienvenu <bienvenu@nventure.com>
> > date:        Tue May 17 12:27:14 2011 -0700
> > summary:     Mike Kaganski <mikekaganski@gmail.com>
> 
> Yes, I messed up the commit comment - it's bug 207156. Do you have a
> reproducible case for this bug, or did you come up with the fix by code
> inspection?

No. At least, nsIFile.GetFileSize or NS_NewLocalFileInputStream returns failure.
Comment on attachment 567404 [details] [diff] [review]
fix

ok, thx for the patch. It could be a virus checker interfering with our access to the file, and not crashing is better than crashing...
Attachment #567404 - Flags: review?(dbienvenu) → review+
http://hg.mozilla.org/comm-central/rev/4124e14e4d5e
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 10.0
Attachment #567404 - Flags: approval-comm-beta?
Attachment #567404 - Flags: approval-comm-aurora?
Attachment #567404 - Flags: approval-comm-beta?
Attachment #567404 - Flags: approval-comm-beta+
Attachment #567404 - Flags: approval-comm-aurora?
Attachment #567404 - Flags: approval-comm-aurora+
You need to log in before you can comment on or make changes to this bug.