Closed Bug 1359230 Opened 8 years ago Closed 7 years ago

ipdl generators should not expose windows.h

Categories

(Core :: IPC, enhancement, P5)

enhancement

Tracking

()

RESOLVED DUPLICATE of bug 1445345

People

(Reporter: bkelly, Unassigned)

References

Details

Attachments

(2 files)

Currently its super easy to shoot yourself in the foot by using an IPC generated type in dom bindings or nsGlobalWindow. This will work on linux/mac, but blow up on windows because they fail to compile when windows.h is included. We should make IPC generated headers not expose windows.h like this. I'll see if I can figure it out. It seems to come from IPCMessageUtils.h pulling in chromium's process_util.h. I assume it hasn;t been fixed before because no one wants to touch the chromium stuff.
Blocks: 1293277
I might be able to do this for simple structs/unions, but anything that includes FileDescriptor (like IPCStream) will require windows.h.
Attached patch bug135920_ipcheaders.patch (deleted) — Splinter Review
First of a number of wip patches.
Attached patch ipc_wip.patch (deleted) — Splinter Review
I think I am going to have to punt on this. The ipdl compiler wants to add ProtoculUtils.h to every generated header for things that are considered "builtin". We could do work to create more granular headers for only builtins that are used, but that would be non-trivial. Instead of this bug I think I am going to abandon using ipdl generated types in bug 1293277. Instead I will roll plain c++ classes with custom serializers.
Assignee: bkelly → nobody
No longer blocks: 1293277
Status: ASSIGNED → NEW
Priority: -- → P5
Nika is working this over in bug 1445345.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: