summaryrefslogtreecommitdiffstats
path: root/perl-install/resize_fat/info_sector.pm
diff options
context:
space:
mode:
authorMystery Man <unknown@mandriva.org>2001-08-07 17:40:36 +0000
committerMystery Man <unknown@mandriva.org>2001-08-07 17:40:36 +0000
commit068d599562888a36a50e5bbdeb8b70f83fa7c287 (patch)
tree18f5eed8353b3af647412875d438b55ef8c07670 /perl-install/resize_fat/info_sector.pm
parentbe838931607e1ab14c8c699e20dd807b55579f7b (diff)
downloaddrakx-backup-do-not-use-topic/v_webmin_0_87.tar
drakx-backup-do-not-use-topic/v_webmin_0_87.tar.gz
drakx-backup-do-not-use-topic/v_webmin_0_87.tar.bz2
drakx-backup-do-not-use-topic/v_webmin_0_87.tar.xz
drakx-backup-do-not-use-topic/v_webmin_0_87.zip
This commit was manufactured by cvs2svn to create branchtopic/v_webmin_0_87
'v_webmin_0_87'.
Diffstat (limited to 'perl-install/resize_fat/info_sector.pm')
-rw-r--r--perl-install/resize_fat/info_sector.pm37
1 files changed, 0 insertions, 37 deletions
diff --git a/perl-install/resize_fat/info_sector.pm b/perl-install/resize_fat/info_sector.pm
deleted file mode 100644
index 35449cedc..000000000
--- a/perl-install/resize_fat/info_sector.pm
+++ /dev/null
@@ -1,37 +0,0 @@
-package resize_fat::info_sector; # $Id$
-
-use diagnostics;
-use strict;
-
-use common;
-use resize_fat::io;
-
-#- Oops, this will be unresizable on big-endian machine. trapped by signature.
-my $format = "a484 I I I a16";
-my @fields = (
- 'unused',
- 'signature', #- should be 0x61417272
- 'free_clusters', #- -1 for unknown
- 'next_cluster', #- most recently allocated cluster
- 'unused2',
-);
-
-1;
-
-
-sub read($) {
- my ($fs) = @_;
- my $info = resize_fat::io::read($fs, $fs->{info_offset}, psizeof($format));
- @{$fs->{info_sector}}{@fields} = unpack $format, $info;
- $fs->{info_sector}{signature} == 0x61417272 or die "Invalid information sector signature\n";
-}
-
-sub write($) {
- my ($fs) = @_;
- $fs->{info_sector}{free_clusters} = $fs->{clusters}->{count}->{free};
- $fs->{info_sector}{next_cluster} = 2;
-
- my $info = pack $format, @{$fs->{info_sector}}{@fields};
-
- resize_fat::io::write($fs, $fs->{info_offset}, psizeof($format), $info);
-}