Commit Graph

11 Commits

Author SHA1 Message Date
Chris Peterson
dd2fcb9b7d Bug 1207030 - Enable -Wshadow flag in more directories that have no -Wshadow warnings. r=glandium 2015-09-22 21:39:03 -07:00
Nicholas Nethercote
69d088e45f Bug 1198334 (part 1) - Replace the opt-in FAIL_ON_WARNINGS with the opt-out ALLOW_COMPILER_WARNINGS. r=glandium.
The patch removes 455 occurrences of FAIL_ON_WARNINGS from moz.build files, and
adds 78 instances of ALLOW_COMPILER_WARNINGS. About half of those 78 are in
code we control and which should be removable with a little effort.
2015-08-27 20:44:53 -07:00
Thomas Zimmermann
92a42ffbe4 Bug 1167210: Replace |union sockaddr_any| with |struct sockaddr_storage|, r=kmachulis
Both types, |union sockaddr_any| and |struct sockaddr_storage|, provide
a sockaddr type that can hold any address. The latter is standardized by
POSIX, so we prefer it.
2015-05-27 13:49:07 +02:00
Thomas Zimmermann
11aef2cf1c Bug 1162524: Move |accept| out of |UnixSocketWatcher|, r=kmachulis
Calls to |accept| are now handled by the corresponding socket I/O
class. This makes the code more flexible. All callers have been
adapted.
2015-05-08 09:43:01 +02:00
Thomas Zimmermann
31aa11a5b6 Bug 1162524: Fix error handling |UnixSocketWatcher::Connect|, r=kmachulis
With this patch, it's not an error if the connection operations
stalls on a non-blocking socket; so don't return an error code.

The patch also makes |connect| restart if it was aborted by a
signal.
2015-05-08 09:42:46 +02:00
Ehsan Akhgari
5cccea6f0f Bug 1145631 - Part 1: Replace MOZ_OVERRIDE and MOZ_FINAL with override and final in the tree; r=froydnj
This patch was automatically generated using the following script:

function convert() {
echo "Converting $1 to $2..."
find . \
       ! -wholename "*/.git*" \
       ! -wholename "obj-ff-dbg*" \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_OVERRIDE override
convert MOZ_FINAL final
2015-03-21 12:28:04 -04:00
Thomas Zimmermann
99d5a28fff Bug 1093025: Initialize listen socket only once in |UnixSocketWatcher::Listen|, r=kyle
Sockets in listen mode may only be created and bound once. This patch fixes
|unixSocketWatcher::Listen| to respect these contraints. Listening more than
once will reuse the settings from the first listen operation.
2014-12-02 15:00:35 -08:00
Ben Tian
40af3a9adb Bug 979668 - [Bluetooth] Sender name is not shown in transfer requests, f=tzimmermann, r=kyle 2014-03-10 10:11:27 +08:00
Thomas Zimmermann
a4d6c7be53 Bug 979858: Add include guards to headers in ipc/unixfd, r=kyle 2014-03-06 09:32:25 +01:00
Thomas Zimmermann
ee103c53d3 Bug 977672: Assert O_NONBLOCK for watched file descriptors, r=kyle
We cannot use blocking file-descriptor I/O on the I/O thread. This
patch adds an assertion to UnixFdWatcher the tests for the O_NONBLOCK
flag, when installing a file descriptor. In UnixFileWatcher, the
Open method tests for the O_NONBLOCK flag for the opened file.

File-descriptor flags for UnixSocketImpl et al are currently set by
UnixSocketImpl itself. Later patches should move this into the
methods of connector classes.
2014-02-28 10:16:52 +01:00
Thomas Zimmermann
a3c1ed41a6 Bug 974410: Added watcher classes for Unix file descriptors, r=kyle
These new classes encasulate file-descriptor watchers, basic file
descriptors, and socket connections. Each class contains callback
methods for it's implemented functionality. Users should inherit
from the classes and overload the callback with their own code.
2014-02-26 17:51:52 +01:00