Overview
Comment: | OFDNSResolver: Make sure queries live long enough |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
d062db67085c998c9c3b6bec0aa3688a |
User & Date: | js on 2018-11-17 23:13:06 |
Other Links: | manifest | tags |
Context
2018-11-24
| ||
13:02 | Fix compilation with --disable-unicode-tables check-in: efedce10f7 user: js tags: trunk | |
2018-11-17
| ||
23:13 | OFDNSResolver: Make sure queries live long enough check-in: d062db6708 user: js tags: trunk | |
22:59 | Various minor style improvements check-in: b090b5ce92 user: js tags: trunk | |
Changes
Modified src/OFDNSResolver.m from [5e69e0a1d6] to [e676e364e2].
︙ | ︙ | |||
1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 | callback(query->_target, query->_selector, self, query->_domainName, nil, nil, nil, query->_context, exception); return 0; } [sock asyncReceiveIntoBuffer: [query allocMemoryWithSize: 512] length: 512 runLoopMode: [[OFRunLoop currentRunLoop] currentMode] target: self selector: @selector(of_socket:didReceiveIntoBuffer: length:sender:context:exception:) | > > > > | | 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 | callback(query->_target, query->_selector, self, query->_domainName, nil, nil, nil, query->_context, exception); return 0; } /* * Pass the query as context to make sure that its buffer stays around * for as long as our receive is pending. */ [sock asyncReceiveIntoBuffer: [query allocMemoryWithSize: 512] length: 512 runLoopMode: [[OFRunLoop currentRunLoop] currentMode] target: self selector: @selector(of_socket:didReceiveIntoBuffer: length:sender:context:exception:) context: query]; return 0; } - (bool)of_socket: (OFUDPSocket *)sock didReceiveIntoBuffer: (unsigned char *)buffer length: (size_t)length |
︙ | ︙ |