Commit Graph

43 Commits (04ebd8256d9061234d5c8a6266ad65fa9dc48cfc)

Author SHA1 Message Date
flatcap 04ebd8256d The addition of one hundred and forty-five linefeeds. Thanks Yura! 2005-12-04 22:42:51 +00:00
cha0smaster a732881c5e see changelog 2005-11-07 20:37:07 +00:00
flatcap 83b9eddfc9 provide some meaningful function descriptions 2005-11-02 17:34:08 +00:00
flatcap 121d05deb6 add/update function comment blocks
(ok, they need words, but it's a start)
2005-10-30 16:12:22 +00:00
cha0smaster a7c595fe3c fix build 2005-10-28 13:17:53 +00:00
uvman 8f43f0ef4c Match parameter names between .h and .c files 2005-10-28 12:47:49 +00:00
flatcap 8892ba7ac6 remove some colour hacks
remove a few #ifdef DEBUGs and RM_WRITEs
throw in lots of extra traces
2005-10-28 04:32:21 +00:00
flatcap f4e427e91a implement logging in libntfs
fix whitespace
fix build problems
tidy source code
and more...
2005-10-21 18:05:13 +00:00
flatcap 2a8d602d9f ntfsrm has been split up and merged into libntfs.
currently it's #ifdef'd out.
tree.c - code for handling directory trees
rich.c - a few helpers without a home (this file will go away soon)
Note: ntfsrm isn't in the build any more (you need to ./configure --enable-rich; make extras).  When rm is less intrusive, again, I'll put it back in the build.
2005-10-16 23:33:03 +00:00
antona 8db479a6b1 Patch from Christophe:
A lot of headers are checked by autoconf (AC_CHECK_HEADERS in configure.ac).
Please find a patch that add the missing "#ifdef" to the source code.
2005-09-28 13:47:47 +00:00
cha0smaster 9028a53dfc Sorry it's very large commit (46K of diffs between my local tree and CVS HEAD
before commit), file and directory creation/deletion recursively requested many
changes. See ChangeLog for description of all changes.
2005-08-14 15:44:46 +00:00
szaka 06052dafcf Replaced all occurances of ENOTSUP to EOPNOTSUPP to be in better harmony
with the kernel driver
2005-08-01 22:10:38 +00:00
flatcap 7a142ef54c got bored. don't read the diffs. 2005-07-06 22:47:01 +00:00
flatcap 949043ab36 Tidy whitespace: trailing space; <space><tab> at the beginning of lines
Fix warnings about sign differences
Fix warnings about unused parameters
Tidy a few functions that didn't have { on a new line
2005-06-19 21:09:40 +00:00
(none)!yura 14db887f8e Rename NTFS_SECTOR_SIZE to NTFS_BLOCK_SIZE to keep in sync with kernel driver.
(Logical change 1.653)
2005-01-11 20:28:28 +00:00
(none)!yura 1c283737c5 Change prototype of ntfs_cluster_alloc like in kernel driver.
(Logical change 1.628)
2004-11-05 20:02:16 +00:00
cantab.net!aia21 3f58b75146 Enforce minimum inode allocation 24 in ntfs_mft_bitmap_find_free_rec().
(Logical change 1.610)
2004-10-13 10:56:24 +00:00
cantab.net!aia21 b81e3f8959 Fix stupid typo where I had >> vol->cluster_size instead of
>> vol->cluster_size_bits.

(Logical change 1.590)
2004-10-01 13:56:42 +00:00
cantab.net!aia21 8b3c03e173 Rename scpu_to_le{16,32,64}() to cpu_to_sle{16,32,64}() to match the kernel.
(Logical change 1.586)
2004-09-30 15:00:31 +00:00
(none)!yura 7443484bdc - fix compiler warnings
(Logical change 1.575)
2004-09-20 17:29:50 +00:00
(none)!yura c30049a41e - more debug output
(Logical change 1.566)
2004-09-19 14:39:47 +00:00
cantab.net!aia21 ba4192c33c Final fixes for ntfs_mft_record_alloc() that fell out from extensive testing.
(Logical change 1.556)
2004-09-16 08:19:32 +00:00
cantab.net!aia21 9656a23b5e Finish off ntfs_mft_record_alloc() and its error handling.
(Logical change 1.554)
2004-09-15 15:21:47 +00:00
cantab.net!aia21 caf2f0ad97 More code refactoring in ntfs_mft_record_alloc() together with more error
recovery code.

(Logical change 1.553)
2004-09-15 12:49:52 +00:00
cantab.net!aia21 0de81b2f41 More work on ntfs_mft_record_alloc(): Factor out some code, start with
some error handling and a bug fix here or there...

(Logical change 1.552)
2004-09-14 13:01:33 +00:00
cantab.net!aia21 8fdb6981ff First cut of ntfs_mft_record_alloc() ported from my old ntfs allocator that
I wrote several years ago.  Note this is completely untested and there is
no error handling at all yet.  I will be porting/adding the error handling
next.  (Anton)

(Logical change 1.551)
2004-09-13 14:44:01 +00:00
cantab.net!aia21 b82469ba50 Remove vol->nr_mft_records and update all users. (Anton)
(Logical change 1.549)
2004-09-13 10:28:54 +00:00
cantab.net!aia21 4910ed561c Change all output to only appear if configure with --enable-debug by
using Dputs/Dprintf instead of fprintf(stderr,.

(Logical change 1.502)
2004-08-18 10:27:49 +00:00
cantab.net!aia21 2bd298bc2d Add new API mft.[hc]::ntfs_mft_record_{layout,format}() and make
mkntfs use it.

(Logical change 1.335)
2004-03-15 12:50:18 +00:00
cantab.net!aia21 cb3b41894a Modify meaning of ntfs_volume->nr_mft_records to be the number of
initialized mft records, not total mft records.  This makes far more
sense and in fact reflects how nr_mft_records is being used in both
libntfs and the utilities.

(Logical change 1.326)
2004-03-12 15:50:52 +00:00
cantab.net!aia21 441947337e Include config.h before any other non-ntfs headers.
(Logical change 1.279)
2004-02-20 14:44:16 +00:00
cantab.net!aia21 c9076ef627 - Apply patch from Szaka to fix all %L to %ll.
- Fix remaining %L ti %ll (compress.c).
- Run ./autogen.sh on SuSE 9.0.

(Logical change 1.263)
2004-01-15 16:57:10 +00:00
cantab.net!aia21 3244f17522 Enable lots of compiler warnings and fix warning from libntfs.
(Logical change 1.257)
2004-01-07 15:03:17 +00:00
cantab.net!aia21 d993588f0c Implement rollback in ntfs_mft_record_free().
(Logical change 1.219)
2003-10-29 17:35:15 +00:00
cantab.net!aia21 7af52becdd common functions moved from diks_io.h to device.h
(Logical change 1.188)
2003-10-06 11:38:25 +00:00
cantab.net!aia21 b42dc41d6a ntfs_mft_records_write(): stupid buffer overflow bug (ouch!)
(Logical change 1.121)
2003-02-13 10:27:33 +00:00
flatcap.org!flatcap 953ac4ff86 sync with Paul
(Logical change 1.82)
2003-01-09 16:30:59 +00:00
cantab.net!aia21 8a3f5f4c00 fix compile (thanks to Szaka)
(Logical change 1.76)
2003-01-06 22:08:00 +00:00
cantab.net!aia21 be6376f85e New API provided by mft.[hc]:
ntfs_mft_record_alloc(), -- WIP
	ntfs_mft_record_free().

(Logical change 1.74)
2002-12-29 21:37:21 +00:00
cantab.net!aia21 69306cc493 new api renames to ntfs_object_action
(Logical change 1.36)
2002-12-10 11:53:41 +00:00
cantab.net!aia21 9e79b61437 start of renames to ntfs_object_action() format
(Logical change 1.34)
2002-12-09 09:42:12 +00:00
!flatcap 6593450759 whitespace and include guards
2002/07/08 06:23:22-00:00 !antona
Don't use string concatenation with __FUNCTION__ as gcc-3.x don't like it.

2002/07/07 19:44:57-00:00 !antona
Change ntfs_read_file_record() not to abort if the inode is not in use. Adapt callers which care to check this themselves.

2002/07/02 23:47:10-00:00 !antona
Global replacement of __[su]{8,16,32,64} with [su]{8,16,32,64} and layout.h define it.

2002/06/08 14:12:01-00:00 !antona
ntfs_readdir() has arrived.

2002/06/05 20:32:53-00:00 !antona
Mft mirror now updated from ntfs_write_mft_record, yey! Fixup ntfstools accordingly.

2002/06/01 00:41:45-00:00 !antona
huge update!

2002/04/27 19:49:09-00:00 !antona
Update library, new APIs ntfs_attr_find_vcn(), misc fixes and cleanups, make all the utilities compile, fix bugs I noticed in ntfslabel and it now works properly.

2002/04/24 23:47:42-00:00 !antona
Hammer out the API for run list merging. Add calls for low level (using raw run lists and ATTR_RECORDs as parameters) run list merging, mappaing pairs decompression, and vcn to lcn conversion as well as high level (using ntfs_attr as parameter) calls for run list mapping and vcn to lcn conversion.

2002/04/22 10:34:31-00:00 !antona
Attribute list support (merging done, part 2, some stuff still incomplete). mkntfs ntfs volume creation. See the changelog...

2002/04/20 23:09:42-00:00 !antona
Port attribute lookup functions with attribute list support from ntfs tng driver. Port/reimplement extent mft record handling code as well. Rename out all dollar signs from type names and constants. Adapt all callers to new API. Note mkntfs is currently broken due to some needed work.

2002/04/20 01:53:02-00:00 !antona
Rename mft code adding ntfs_ prefix. Change all return values to zero on success. Thanks to mattjf for pointing out the inconsistencies.

2002/04/16 12:13:53-00:00 !antona
New API function mft.[ch]::read_file_record(). Also some cleanups.

2002/04/15 20:04:27-00:00 !antona
Fix all compiler warnings that came up with -Wall. Enabled -Wall for ./configure --enable-debug everywhere. Fix a few bugs in mkntfs that came up in the warnings (just error code paths, nothing major).

2002/04/15 19:02:40-00:00 !antona
Really fix the library and mkntfs while at it.

2002/04/15 18:54:07-00:00 !antona
Update library for the new API.

2002/04/15 18:39:37-00:00 !antona
Cleanup some mistakes.

2002/04/15 17:51:26-00:00 !antona
read/write_mft_record(s) are here

2002/04/15 00:42:07-00:00 !antona
Big rewrite of disk_io.c. Now should have stable API for low level disk access. Move all mft record related stuff from disk_io.c to mft.c.

2002/04/14 14:08:30-00:00 !antona
Cleanup library code. Throw away unused stuff.

2002/04/14 13:34:49-00:00 !antona
Throw away all unnecessary crap.

2001/12/15 05:13:08-00:00 !antona
Remove atomic ops and add compiler version check.

2001/06/01 02:07:26-00:00 !antona
It has been a long time since last commit. At moment have done a lot of work
on mkntfs but also at the moment ntfsfix and ntfsdump_logfile and libntfs are
broken. Basically only mkntfs works and that is not complete either.

2001/04/11 14:29:12-00:00 !antona
Almost fixed compilaton. Remember to declare a struct type with
struct NAME { declaration }; rather than the bogus struct { declaration NAME };
then can use typedef NAME othername; on a forward declaration of NAME
(struct NAME;) and all is fine...

2001/04/11 11:49:16-00:00 !antona

Header file reorganisation so that it compiles.

2001/04/10 23:37:19-00:00 !antona
Ok, ntfsd was a mistake for userspace. It increases complexity no end while
not giving us much functionality. Lets get it working and then worry about the
kernel. - As it was the idea originally anyway, so this is just a return on the
right track. (-8

We keep the timer and signal handler but the only thing we do is to set a bool
flag (ntfs_need_sync) and we will just check this in appropriate places and
if it is true we call ntfs_sync_volumes() which sets it back to false. This
means no more locking at all of any description and no need to worry about the
signal handler interrupting things in bad ways and/or at bad times in the main
code.

2001/04/09 00:05:37-00:00 !antona
More or less finished file handling. (Probably some useful functions are
still missing but they will be implemented as need arises.)

One thing that is stupid at the moment is we don't limit the amount of
cached mft_records so if you were to load loads the machine would eventually
run out of memory... Can't happen with files as they are limited to 1000,
unless you are short of memory. (Hard limit at the moment, set in ntfs_mount().
Maybe ntfsd should be monitoring memory usage and be throwing out unused cache
entries and closed_files? That would mean to have locking everywhere, though.)

Still missing: - Convert old code to use new stuff. - Add non-resident
attributes somewhere. Either into the mft_entry structure or into the
ntfs_file structure, but which? At the moment I tend to mft_entry so they can
be synced together with the entries by ntfsd.

2001/04/08 01:58:29-00:00 !antona
User space conversion of locking complete. I settled for using simple spinlocks
and atomic variables and instead of deadlocking/livelocking when using
spin_lock(), use spin_trylock() in a while letting go of the cpu between each
call and making a maximum of 100 iterations (or we return EDEADLK error code).

This is not the most efficient way, especially as can't have multiple readers
but it is the simplest way to go about things.

Should now have (almost) all required helper functions for dealing with mft
entries implemented.

Now need the file handling and then convert the whole project to use the new
code and then can finally get back to work on attribute searching...

2001/04/05 20:14:45-00:00 !antona
Commit of current state of development including locking a la kernel.
This doesn't work on user space (semaphores don't work).
Just want to have it committed. Will take out locking / modify it where
necessary to use pthreads ASAP.

2001/04/03 23:38:34-00:00 !antona
Mark mft entry dirty function complete

2001/03/05 03:04:40-00:00 !antona
Corresponding changes to the library.

2001/01/25 22:25:43-00:00 !antona
More files added to ntfs lib. Fixed some consistency problems.

(Logical change 1.5)
2002-08-22 18:09:47 +00:00
!flatcap aaf8f8e036 Initial revision 2002-08-22 18:09:47 +00:00