rpms/util-linux/devel util-linux-2.13-cramfs-maxentries.patch, NONE, 1.1 util-linux.spec, 1.91, 1.92
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Thu Oct 20 21:58:24 UTC 2005
- Previous message (by thread): rpms/anaconda/devel .cvsignore, 1.152, 1.153 anaconda.spec, 1.268, 1.269 sources, 1.270, 1.271
- Next message (by thread): rpms/pup/devel .cvsignore,1.6,1.7 pup.spec,1.7,1.8 sources,1.8,1.9
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: kzak
Update of /cvs/dist/rpms/util-linux/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv30294
Modified Files:
util-linux.spec
Added Files:
util-linux-2.13-cramfs-maxentries.patch
Log Message:
fix cramfs
util-linux-2.13-cramfs-maxentries.patch:
mkfs.cramfs.c | 21 ++++++++++++---------
1 files changed, 12 insertions(+), 9 deletions(-)
--- NEW FILE util-linux-2.13-cramfs-maxentries.patch ---
--- util-linux-2.13-pre5/disk-utils/mkfs.cramfs.c.maxentries 2005-10-20 23:46:19.000000000 +0200
+++ util-linux-2.13-pre5/disk-utils/mkfs.cramfs.c 2005-10-20 23:54:07.000000000 +0200
@@ -471,11 +471,13 @@
* entries, using a stack to remember the directories
* we've seen.
*/
-#define MAXENTRIES (100)
static unsigned int write_directory_structure(struct entry *entry, char *base, unsigned int offset)
{
int stack_entries = 0;
- struct entry *entry_stack[MAXENTRIES];
+ int stack_size = 64;
+ struct entry **entry_stack;
+
+ entry_stack = xmalloc(stack_size * sizeof(struct entry *));
for (;;) {
int dir_start = stack_entries;
@@ -508,13 +510,13 @@
if (verbose)
printf(" %s\n", entry->name);
if (entry->child) {
- if (stack_entries >= MAXENTRIES) {
- fprintf(stderr,
- _("Exceeded MAXENTRIES. Raise"
- " this value in mkcramfs.c "
- "and recompile. Exiting.\n")
- );
- exit(8);
+ if (stack_entries >= stack_size) {
+ stack_size *= 2;
+ entry_stack = realloc(entry_stack, stack_size * sizeof(struct entry *));
+ if (!entry_stack) {
+ perror(NULL);
+ exit(8); /* out of memory */
+ }
}
entry_stack[stack_entries] = entry;
stack_entries++;
@@ -551,6 +553,7 @@
printf("'%s':\n", entry->name);
entry = entry->child;
}
+ free(entry_stack);
return offset;
}
Index: util-linux.spec
===================================================================
RCS file: /cvs/dist/rpms/util-linux/devel/util-linux.spec,v
retrieving revision 1.91
retrieving revision 1.92
diff -u -r1.91 -r1.92
--- util-linux.spec 20 Oct 2005 14:54:21 -0000 1.91
+++ util-linux.spec 20 Oct 2005 21:58:21 -0000 1.92
@@ -25,7 +25,7 @@
Summary: A collection of basic system utilities.
Name: util-linux
Version: 2.13
-Release: 0.6.pre5
+Release: 0.7.pre5
License: distributable
Group: System Environment/Base
@@ -155,6 +155,8 @@
Patch215: util-linux-2.13-audit-login.patch
# 170171 - ipcs -lm always report "max total shared memory (kbytes) = 0"
Patch216: util-linux-2.13-ipcs-shmax.patch
+# 171337 - mkfs.cramfs dies creating installer image
+Patch217: util-linux-2.13-cramfs-maxentries.patch
# When adding patches, please make sure that it is easy to find out what bug # the
# patch fixes.
@@ -221,8 +223,10 @@
%patch212 -p1
%patch213 -p1
%patch214 -p1
+# audit
%patch215 -p1
%patch216 -p1
+%patch217 -p1
%build
unset LINGUAS || :
@@ -606,6 +610,9 @@
/sbin/losetup
%changelog
+* Thu Oct 20 2005 Karel Zak <kzak at redhat.com> 2.13-0.7.pre5
+- fix #171337 - mkfs.cramfs dies creating installer image
+
* Thu Oct 20 2005 Karel Zak <kzak at redhat.com> 2.13-0.6.pre5
- update to upstream 2.13pre5
- remove separated cramfs1.1 (already in upstream package)
- Previous message (by thread): rpms/anaconda/devel .cvsignore, 1.152, 1.153 anaconda.spec, 1.268, 1.269 sources, 1.270, 1.271
- Next message (by thread): rpms/pup/devel .cvsignore,1.6,1.7 pup.spec,1.7,1.8 sources,1.8,1.9
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-cvs-commits
mailing list