diff --git a/proxygen/lib/dns/Rfc6724.cpp b/proxygen/lib/dns/Rfc6724.cpp index b036488d08..8afab82c67 100644 --- a/proxygen/lib/dns/Rfc6724.cpp +++ b/proxygen/lib/dns/Rfc6724.cpp @@ -68,6 +68,12 @@ namespace proxygen { void rfc6724_sort(vector& addrs, const SocketAddress* srcAddr /* = nullptr */) { + /** + * Some callers require strong exception safety guarentees. If `find_src_addr` + * throws an exception, the output (e.g. vector& addrs) must + * be left in a valid state; this is a note to prevent future developers from + * breaking this guarantee. + */ vector sortVec; for (size_t i = 0; i < addrs.size(); ++i) { SortElement elem;