Displaying 5 results from an estimated 5 matches for "c32file".
2015 Nov 13
4
[PATCH 1/4] extlinux: simplification
...(int)syslinux_ldlinuxc32_len) {
+ fprintf(stderr, "%s: write failure on %s\n", program, file);
+ rv = 1;
+ } else
+ rv = 0;
+
+ close(fd);
+ free(file);
+
+ return rv;
+}
+
int ext2_fat_install_file(const char *path, int devfd, struct stat *rst)
{
- char *file, *oldfile, *c32file;
+ char *file, *oldfile;
int fd = -1, dirfd = -1;
- int r1, r2, r3;
+ int r1, r2;
r1 = asprintf(&file, "%s%sldlinux.sys",
path, path[0] && path[strlen(path) - 1] == '/' ? "" : "/");
r2 = asprintf(&oldfile, "%s...
2015 Sep 09
1
[PATCH v1 1/1] extlinux: fix file descriptors leak
...diff --git a/extlinux/main.c b/extlinux/main.c
index 09740bd..55a1495 100644
--- a/extlinux/main.c
+++ b/extlinux/main.c
@@ -580,6 +580,7 @@ int ext2_fat_install_file(const char *path, int devfd, struct stat *rst)
goto bail;
}
+ close(fd);
free(file);
free(oldfile);
free(c32file);
@@ -778,7 +779,7 @@ static char * get_default_subvol(char * rootdir, char * subvol)
struct btrfs_ioctl_search_key *sk = &args.key;
struct btrfs_ioctl_search_header *sh;
int ret, i;
- int fd;
+ int fd = -1;
struct btrfs_root_ref *ref;
struct btrfs_dir_item *dir_i...
2015 Sep 09
0
[PATCH v1 1/1] extlinux: fix file descriptors leak
...diff --git a/extlinux/main.c b/extlinux/main.c
index 09740bd..bc7ded3 100644
--- a/extlinux/main.c
+++ b/extlinux/main.c
@@ -580,6 +580,7 @@ int ext2_fat_install_file(const char *path, int devfd, struct stat *rst)
goto bail;
}
+ close(fd);
free(file);
free(oldfile);
free(c32file);
@@ -797,6 +798,8 @@ static char * get_default_subvol(char * rootdir, char * subvol)
}
if (ret <= 0) {
subvol[0] = '\0';
+ if (fd >= 0)
+ close(fd);
return NULL;
}
@@ -831,6 +834,8 @@ static char * get_default_subvol(char * rootdir...
2014 Dec 24
14
[PATCH 0/8] extlinux: support unmounted ext2/3/4 filesystem
Hello syslinux,
Merry Christmas! These patches will make extlinux work with umounted
ext2/3/4 filesystem, for example:
$ extlinux -i /dev/sdXN
or
$ extlinux -i file_block
Also it can work with something like:
$ extlinux /dev/sdXN --reset-adv
or
$ extlinux file_block --reset-adv
We don't use a new option (I planed to use "-d" but it is already in
use), it will check whether the
2015 Jan 02
13
[PATCH 0/9] linux/syslinux: support ext2/3/4 device
Hello,
Happy New Year!
These patches make syslinux/linux support ext2/3/4, and it doesn't
require the root privilege, I'd like to add a separate e2fs/syslinux, if
that is more appropriate, it should be easy to do that.
I put these patches on github so that you can easily get them in case
you'd like to test them. (The repo's name is sys_tmp, which avoids
confusing others, I will