Explorar o código

Update select.c

heyuanjie87 %!s(int64=7) %!d(string=hai) anos
pai
achega
c90b449dac
Modificáronse 1 ficheiros con 5 adicións e 1 borrados
  1. 5 1
      components/dfs/src/select.c

+ 5 - 1
components/dfs/src/select.c

@@ -32,7 +32,11 @@ static void fdzero(fd_set *set, int nfds)
 {
     fd_mask *m;
     int n;
-
+    
+    /*
+      The 'sizeof(fd_set)' of the system space may differ from user space,
+      so the actual size of the 'fd_set' is determined here with the parameter 'nfds'
+    */
     m = (fd_mask*)set;
     for (n = 0; n < nfds; n += (sizeof(fd_mask) * 8))
     {