Closed Bug 450222 Opened 16 years ago Closed 16 years ago

Add a new header include into extensions/auth/nsAuthSSPI.h

Categories

(Firefox :: General, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: Techrazy.Yang, Unassigned)

References

Details

Attachments

(1 file, 3 obsolete files)

Attached patch A trivial path (obsolete) — Splinter Review
Without this header, there will be some undeclared types compile errors when compiling with Mingw. 

Could anybody tell, to whom I should ask review for this patch?
Blocks: 450092
What types were undefined? This code isn't well-owned, so I can review this if necessary, but I'd like to see some MSDN docs about the functions or types in question.
The errors are something like:

In file included from /home/byang/mingw-install/lib/gcc/i686-mingw32/4.3.0/../../../../i686-mingw32/include/security.h:38,
                 from /home/byang/mozilla-central/extensions/auth/nsAuthSSPI.h:48,
                 from /home/byang/mozilla-central/extensions/auth/nsAuthFactory.cpp:72:
/home/byang/mingw-install/lib/gcc/i686-mingw32/4.3.0/../../../../i686-mingw32/include/sspi.h:60: error: ‘UNICODE_STRING’ does
 not name a type
In file included from /home/byang/mingw-install/lib/gcc/i686-mingw32/4.3.0/../../../../i686-mingw32/include/security.h:39,
                 from /home/byang/mozilla-central/extensions/auth/nsAuthSSPI.h:48,
                 from /home/byang/mozilla-central/extensions/auth/nsAuthFactory.cpp:72:
/home/byang/mingw-install/lib/gcc/i686-mingw32/4.3.0/../../../../i686-mingw32/include/ntsecpkg.h:123: error: ‘SECURITY_STRING
’ does not name a type

In Mingw the UNICODE_STRING is defined in subauth.h, but in Windows SDK, it is not defined in that header, that is why only the mingw build incur this error. See  http://msdn.microsoft.com/en-us/library/aa492030.aspx, UNICODE_STRING is defined in ntdef.h. 
So, I revised the patch... 
Attached patch A second version (obsolete) — Splinter Review
Attachment #333373 - Attachment is obsolete: true
Attachment #333493 - Flags: review?(benjamin)
According to MSDN, we should include ntsecapi.h... does that work in mingw?

http://msdn.microsoft.com/en-us/library/aa380518(VS.85).aspx
(In reply to comment #4)
> According to MSDN, we should include ntsecapi.h... does that work in mingw?
> 
> http://msdn.microsoft.com/en-us/library/aa380518(VS.85).aspx

To my surprise, there is a UNICODE_STRING exactly the same in the both header files . I think I will file a bug for w32api for the redundant definition. 

Use the ntsecapi.h according MSDN. 
Attached patch Third version (obsolete) — Splinter Review
Attachment #333554 - Flags: review?(benjamin)
Comment on attachment 333554 [details] [diff] [review]
Third version

Just include it unconditionally.
Attachment #333554 - Flags: review?(benjamin) → review-
Attached patch Forth versionSplinter Review
Attachment #333493 - Attachment is obsolete: true
Attachment #333554 - Attachment is obsolete: true
Attachment #333556 - Flags: review?(benjamin)
Attachment #333493 - Flags: review?(benjamin)
Attachment #333556 - Flags: review?(benjamin) → review+
Pushed to mozilla-central, revision f40ef1c6180b
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: