[Tfug] How do you remove a file from a USB vfat - in c

jblais joe.blais at pti-instruments.com
Thu Nov 8 13:35:30 MST 2007


Rob,

No error,
It did seem to work when I was running everything as root
Then to run as a kiosk  (/home/user/.gnome2/session file and
/etc/gdm/options.conf do the trick) I need to run as user, but to access IO
and mount USB and open serial ports, I need some apps to be owned by root
though they are run by a user. When these guys create files and such, they
are owned by root, so I do a bunch of chown/fchown to fix that, then....

But the file does at times seem to be gone, and they are definitely nuked to
0 length.  I'm checking on my unmount not to see that the force unmount
isn't the problem.

Anyway, it looks slick powering up and just going into a full screen app
with no login or anything, and when it shuts down, no desktop for users to
mess with (the script just has a loop to restart the app if anything does go
south)

Joe


> -----Original Message-----
> From: tfug-bounces at tfug.org [mailto:tfug-bounces at tfug.org]On Behalf Of
> Robert Hunter
> Sent: Thursday, November 08, 2007 12:57 PM
> To: Tucson Free Unix Group
> Subject: Re: [Tfug] How do you remove a file from a USB vfat - in c
>
>
> On Nov 8, 2007 12:41 PM, jblais <joe.blais at pti-instruments.com> wrote:
> > I'm trying that now.  IN the clib reference it shows unlink()
> and rmdir(),
> > and at the bottom it lists remove() as the ISO C standard for
> both unlink
> > and rmdir -- but, you never know....
>
> Hi, Joe.  A few questions: Does remove() return an error?  Is the
> filesystem mounted in a peculiar way?  Have you tried "strace-ing"
> the code?
>
> --
> RH
>
> _______________________________________________
> Tucson Free Unix Group - tfug at tfug.org
> Subscription Options:
> http://www.tfug.org/mailman/listinfo/tfug_tfug.org
>
>





More information about the tfug mailing list