Changeset 1794 in kBuild
- Timestamp:
- Sep 19, 2008 11:49:42 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kmk/dir.c
r1450 r1794 219 219 # else 220 220 #define DIRECTORY_BUCKETS 199 221 # endif 221 # endif 222 222 #endif 223 223 … … 565 565 else 566 566 { 567 #ifdef KMK 568 int buckets = st.st_nlink * 2; 569 if (buckets < DIRFILE_BUCKETS) 570 buckets = DIRFILE_BUCKETS; 571 hash_init (&dc->dirfiles, buckets, 572 dirfile_hash_1, dirfile_hash_2, dirfile_hash_cmp); 573 #else 567 574 hash_init (&dc->dirfiles, DIRFILE_BUCKETS, 568 575 dirfile_hash_1, dirfile_hash_2, dirfile_hash_cmp); 576 #endif 569 577 /* Keep track of how many directories are open. */ 570 578 ++open_directories; … … 688 696 if (d == 0) 689 697 { 690 /* bird: Workaround for smbfs mounts returning EBADF at the end of the search. 698 /* bird: Workaround for smbfs mounts returning EBADF at the end of the search. 691 699 To exactly determin the cause here, I should probably do some smbfs 692 tracing, but for now just ignoring the EBADF on seems to work. 700 tracing, but for now just ignoring the EBADF on seems to work. 693 701 (The smb server is 64-bit vista, btw.) */ 694 702 #if defined (__FreeBSD__) … … 701 709 && !strcmp(stfs.f_fstypename, "smbfs")) 702 710 { 703 /*fprintf (stderr, "EBADF on remote fs! dirfd=%d errno=%d\n", 711 /*fprintf (stderr, "EBADF on remote fs! dirfd=%d errno=%d\n", 704 712 dirfd (dir->dirstream), errno);*/ 705 713 saved_errno = 0; … … 1109 1117 hash_print_stats (&dir->contents->dirfiles, stdout); 1110 1118 fputs ("\n", stdout); 1111 #endif 1119 #endif 1112 1120 } 1113 1121 } … … 1131 1139 hash_print_stats (&directory_contents, stdout); 1132 1140 fputs ("\n", stdout); 1133 #endif 1141 #endif 1134 1142 } 1135 1143
Note:
See TracChangeset
for help on using the changeset viewer.