Questions tagged [nftw]

18 questions
0
votes
0 answers

How to read ntfs partition with ntfw

I use grub and put one distro tinycore linux on windows partition(c:/).I don't know why ntfw doesn't read this partition(sda1).I use this partition(in memory). Below is the code and without "FTW_MOUNT" it will fail #define _XOPEN_SOURCE 600 #include…
nimday
  • 333
  • 3
  • 9
0
votes
1 answer

How to delete content of directory using ftw

We can delete non-empty directory using ftw using FTW_DEPTH. But I want to delete content of directory but not directory itself some thing similar to rm -rf dir/*. How to achieve this using nftp/ftw ?
Karna
  • 1
  • 1
0
votes
1 answer

nftw passing tflag with undefined value

While traversing a directory using nftw like so, nftw((argc < 2) ? "." : argv[1], rm, 20, FTW_DEPTH|FTW_PHYS) nftw is passing a value of 5 to the rm function's tflag parameter when it encounters a directory. The ftw.h header only specifies an enum…
spike.barnett
  • 170
  • 1
  • 8
1
2