UTIL *****/ * @brief Utility function to find the highest number in a vector (typically, * the highest file descriptor) */
| 40 | * the highest file descriptor) |
| 41 | */ |
| 42 | int highestfd(const std::vector<int>& v) { |
| 43 | std::vector<int>::const_iterator end = v.end(); |
| 44 | int highestfd = 0; |
| 45 | |
| 46 | for (std::vector<int>::const_iterator cur = v.begin(); cur != end; cur++) { |
| 47 | if (*cur > highestfd) highestfd = *cur; |
| 48 | } |
| 49 | |
| 50 | return highestfd; |
| 51 | } |
| 52 | |
| 53 | } // namespace libsocket |
nothing calls this directly
no outgoing calls
no test coverage detected