Changeset 246682 in webkit


Ignore:
Timestamp:
Jun 21, 2019 10:12:36 AM (5 years ago)
Author:
youenn@apple.com
Message:

Make sure to check for file descriptor value before using FD_CLR
https://bugs.webkit.org/show_bug.cgi?id=199097
<rdar://problem/51479074>

Reviewed by Eric Carlson.

  • Source/webrtc/rtc_base/physicalsocketserver.cc:
  • WebKit/0001-fix-fd-clr.patch: Added.
Location:
trunk/Source/ThirdParty/libwebrtc
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/ThirdParty/libwebrtc/ChangeLog

    r246358 r246682  
     12019-06-21  Youenn Fablet  <youenn@apple.com>
     2
     3        Make sure to check for file descriptor value before using FD_CLR
     4        https://bugs.webkit.org/show_bug.cgi?id=199097
     5        <rdar://problem/51479074>
     6
     7        Reviewed by Eric Carlson.
     8
     9        * Source/webrtc/rtc_base/physicalsocketserver.cc:
     10        * WebKit/0001-fix-fd-clr.patch: Added.
     11
    1122019-06-12  Youenn Fablet  <youenn@apple.com>
    213
  • trunk/Source/ThirdParty/libwebrtc/Source/webrtc/rtc_base/physicalsocketserver.cc

    r244672 r246682  
    14251425        // FD_SETSIZE will result in undefined behavior.
    14261426        RTC_DCHECK_LT(fd, FD_SETSIZE);
     1427#if defined(WEBRTC_WEBKIT_BUILD)
    14271428        if (fd < 0 || fd >= FD_SETSIZE)
    14281429            continue;
     1430#endif
    14291431        if (fd > fdmax)
    14301432          fdmax = fd;
     
    14631465      for (Dispatcher* pdispatcher : dispatchers_) {
    14641466        int fd = pdispatcher->GetDescriptor();
    1465 
     1467#if defined(WEBRTC_WEBKIT_BUILD)
     1468        if (fd < 0 || fd >= FD_SETSIZE)
     1469          continue;
     1470#endif
    14661471        bool readable = FD_ISSET(fd, &fdsRead);
    14671472        if (readable) {
Note: See TracChangeset for help on using the changeset viewer.