]> ruderich.org/simon Gitweb - coloredstderr/coloredstderr.git/commitdiff
Add likely() to tracked_fds_find().
authorSimon Ruderich <simon@ruderich.org>
Sat, 14 Sep 2013 22:15:50 +0000 (00:15 +0200)
committerSimon Ruderich <simon@ruderich.org>
Sat, 14 Sep 2013 22:15:50 +0000 (00:15 +0200)
src/trackfds.h

index 243e8e0d62d33d6f563d525c4f892a92a99ea25d..d45f1281ca9544620177488865a1d4dea022d3d6 100644 (file)
@@ -402,7 +402,7 @@ inline static int tracked_fds_find(int fd) {
         return 0;
     }
 
-    if (fd < TRACKFDS_STATIC_COUNT) {
+    if (likely(fd < TRACKFDS_STATIC_COUNT)) {
         return tracked_fds[fd];
     }