Closed
Bug 745349
Opened 14 years ago
Closed 13 years ago
Various run-only-one-instance bugs in media/webrtc/signaling
Categories
(Core :: WebRTC: Signaling, defect)
Core
WebRTC: Signaling
Tracking
()
RESOLVED
FIXED
People
(Reporter: jesup, Assigned: jesup)
Details
(Whiteboard: [qa-])
Attachments
(1 file)
|
12.76 KB,
patch
|
ehugg
:
feedback+
emannion
:
feedback+
|
Details | Diff | Splinter Review |
There are several instances of using msg queues based on a non-unique identifier/filename in sipcc, such as ftok("/tmp",id), IPC filenames for sockets, etc.
| Assignee | ||
Comment 1•14 years ago
|
||
| Assignee | ||
Comment 2•14 years ago
|
||
Verified on Fedora 15 that the cprCreateMessageQueue() creates unique queues using ftok("/proc/self"...) when multiple instances are run at once.
Assignee: nobody → rjesup
| Assignee | ||
Comment 3•14 years ago
|
||
Comment on attachment 614921 [details] [diff] [review]
remove a set of dependencies on non-unique files/queue names in sipcc
I don't think I need feedback from more than one of you, but I think any of you could review this patch.
Attachment #614921 -
Flags: feedback?(snandaku)
Attachment #614921 -
Flags: feedback?(ethanhugg)
Attachment #614921 -
Flags: feedback?(emannion)
Comment 4•14 years ago
|
||
My initial reaction is this needs testing straight away as any changes to msg queue or socket needs to be very delicate or may cause harm. I would like discuss this work some more when we ext meet.
Comment 5•14 years ago
|
||
Comment on attachment 614921 [details] [diff] [review]
remove a set of dependencies on non-unique files/queue names in sipcc
does using getpid() for the socket name give us uniqueness when FF runs on one process?
Comment 6•14 years ago
|
||
Comment on attachment 614921 [details] [diff] [review]
remove a set of dependencies on non-unique files/queue names in sipcc
Review of attachment 614921 [details] [diff] [review]:
-----------------------------------------------------------------
I was able to run two instances on 64bit Ubuntu 11.10 with the same behavior as Randell's Fedora15 box. So it appears to work.
| Assignee | ||
Comment 7•14 years ago
|
||
(In reply to enda mannion (:emannion) from comment #5)
> Comment on attachment 614921 [details] [diff] [review]
> remove a set of dependencies on non-unique files/queue names in sipcc
>
> does using getpid() for the socket name give us uniqueness when FF runs on
> one process?
getpid() will be the same for the same firefox, even if you have separate tabs/instances. So this does not make them unique if we're to run multiple instances within the same FF. Easiest solution there would be to either use the ftok("/proc/self",counter) trick with a global counter we increment, or combine pid_t with a counter (snprintf(foo,"%s_%d_%u",name,pid,counter)). pid keeps the different copies running on the system from colliding (as /proc/self does with ftok()).
Updated•14 years ago
|
Attachment #614921 -
Flags: feedback?(ethanhugg) → feedback+
| Assignee | ||
Comment 8•14 years ago
|
||
Comment on attachment 614921 [details] [diff] [review]
remove a set of dependencies on non-unique files/queue names in sipcc
I'm going to wait on Enda's comments per our last exchange before committing to alder/default. Suhas, feel free to chime in too.
Comment 9•14 years ago
|
||
Comment on attachment 614921 [details] [diff] [review]
remove a set of dependencies on non-unique files/queue names in sipcc
No major comments on this except I would be keen to see this tested on Mac and maybe Windows ASAP. A more general comment while going through code like this there are still some unused lines that could be tidied up as we see them for example. In cpr_win_socket.h
/* End of nokelly's adds */
//extern const cpr_in6_addr_t in6addr_any;
Not a big issue.
Updated•13 years ago
|
QA Contact: jsmith
Comment 10•13 years ago
|
||
Comment on attachment 614921 [details] [diff] [review]
remove a set of dependencies on non-unique files/queue names in sipcc
Review of attachment 614921 [details] [diff] [review]:
-----------------------------------------------------------------
This has been outstanding for way too long.
Attachment #614921 -
Flags: feedback?(emannion) → feedback+
| Assignee | ||
Comment 11•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Updated•13 years ago
|
Whiteboard: [qa-]
| Assignee | ||
Updated•13 years ago
|
Attachment #614921 -
Flags: feedback?(snandaku)
You need to log in
before you can comment on or make changes to this bug.
Description
•