Lines Matching refs:dirent
343 struct ext2_dir_entry_2 *dirent; in scramble_dir_block() local
348 dirent = (struct ext2_dir_entry_2 *) p; in scramble_dir_block()
349 rec_len = dirent->rec_len; in scramble_dir_block()
355 printf("rec_len = %d, name_len = %d\n", rec_len, dirent->name_len); in scramble_dir_block()
365 dirent->rec_len = ext2fs_swab16(rec_len); in scramble_dir_block()
369 if (dirent->name_len + 8 > rec_len) { in scramble_dir_block()
372 dirent->name_len); in scramble_dir_block()
373 dirent->name_len = rec_len - 8; in scramble_dir_block()
377 len = rec_len - dirent->name_len - 8; in scramble_dir_block()
379 memset(cp+dirent->name_len, 0, len); in scramble_dir_block()
380 if (dirent->name_len==1 && cp[0] == '.') in scramble_dir_block()
382 if (dirent->name_len==2 && cp[0] == '.' && cp[1] == '.') in scramble_dir_block()
385 memset(cp, 'A', dirent->name_len); in scramble_dir_block()
386 len = dirent->name_len; in scramble_dir_block()