Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Sparse files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sparse files



In <email@hidden>, Paul J. Lucas <email@hidden> typed:
> 	Also, how can you tell if a file really is sparse?  I.e., find
> 	out how much disk is actually allocated to it rather than what
> 	"ls" says?

stat(2) the file. The st_blocks fields tells you the number of
512-byte blocks allocated for the file; st_size is what ls reports.

	<mike
--
Mike Meyer <email@hidden>		http://www.mired.org/consulting.html
Independent Network/Unix/Perforce consultant, email for more information.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Unix-porting mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Sparse files (From: "Paul J. Lucas" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.