search for: origdir

Displaying 11 results from an estimated 11 matches for "origdir".

2018 Oct 30
2
Re: [PATCH nbdkit 4/4] Add floppy plugin.
...rtual> wasted space it isn't really > +important, and it simplifies the implementation greatly. > + > +++ b/plugins/floppy/virtual-floppy.c > +static ssize_t > +visit (const char *dir, struct virtual_floppy *floppy) > +{ > + void *np; > + size_t di; > + char *origdir; > + DIR *DIR; > + struct dirent *d; > + int err; > + struct stat statbuf; > + > + /* Allocate a new index in the directory array. Note that the root > + * directory will always be at dirs[0]. > + */ > + di = floppy->nr_dirs; > + np = realloc (floppy-&gt...
2006 May 18
0
Documentation for the plugins you use
...t) Dir.glob("vendor/plugins/*").each do |relPath| plugin = File.split(relPath).last puts relPath + ", " + plugin outfile.write(" <a href=\"#{relPath}/doc/rdoc/index.html\" target=\"_plugins\">#{plugin}</a><br/>\n"); origDir = Dir.pwd begin Dir.chdir(relPath) r = RDoc::RDoc.new r.document ["--op","doc/rdoc", "-S", "--main", "README"] + Dir.glob("*") rescue RDoc::RDocError => e $stderr.puts e.message ensure Dir.chdir origD...
2007 Mar 16
1
git + autogen.sh + configure.ac + po/Makefile.in
What happend with po/Makefile.in and po/Makefile.in in configure.ac? config.status: error: cannot find input file: po/Makefile.in.in configure: error: ./configure failed for compiz Making install in compiz make[1]: Entering directory `/usr/src/SOURCES/TESTING/compiz' Making install in include make[2]: Entering directory `/usr/src/SOURCES/TESTING/compiz/include' make[3]: Entering directory
2018 Oct 28
6
[PATCH nbdkit 0/4] Add floppy plugin.
Add nbdkit-floppy-plugin, “inspired” by qemu's VVFAT driver, but without the ability to handle writes. The implementation is pretty complete, supporting FAT32, LFNs, volume labels, timestamps, etc, and it passes both ‘make check’ and ‘make check-valgrind’. Usage is simple; to serve the current directory: $ nbdkit floppy . Then using guestfish (or any NBD client): $ guestfish --ro
2018 Oct 28
0
[PATCH nbdkit 4/4] Add floppy plugin.
...e (floppy->dirs); +} + +/* Visit files and directories. + * + * This constructs the floppy->dirs and floppy->files lists. + * + * Returns the directory index, or -1 on error. + */ +static ssize_t +visit (const char *dir, struct virtual_floppy *floppy) +{ + void *np; + size_t di; + char *origdir; + DIR *DIR; + struct dirent *d; + int err; + struct stat statbuf; + + /* Allocate a new index in the directory array. Note that the root + * directory will always be at dirs[0]. + */ + di = floppy->nr_dirs; + np = realloc (floppy->dirs, sizeof (struct dir) * (di+1)); + if (np ==...
2019 Feb 19
0
[PATCH nbdkit 4/4] Add linuxdisk plugin.
...-1; + } + else if (WIFSTOPPED (r)) { + nbdkit_error ("mke2fs command was stopped by signal %d", WSTOPSIG (r)); + return -1; + } + + return 0; +} + +static int +visit (const char *dir, ext2_filsys fs, ext2_ino_t dir_ino, + struct file **files, size_t *nr_files) +{ + char *origdir; + DIR *DIR; + struct dirent *d; + struct stat statbuf; + int err; + char *subname = NULL; + + /* Because this is called from config_complete, before nbdkit + * daemonizes or starts any threads, it's safe to use chdir here and + * greatly simplifies the code. However we must chdir ba...
2010 May 17
1
Useful NFS hint
Don't do NFS localhost mounts from fstab eg localhost:/origdir /newdir nfs ro 0 0 (Indeed, don't do localhost NFS mounts at all). Why? Because at shutdown time nfsd is terminated before the unmounting, so the shutdown hangs trying to access NFS server localhost. And at boot time it tries to do NFS mounts before nfsd starts up. _sigh_ -- rgds Stephen
2019 Feb 19
6
[PATCH nbdkit v2 0/5] Add linuxdisk plugin.
...: https://github.com/libguestfs/nbdkit/blob/72e0afe2e280d895f68941677fafa559ddc3bb0d/plugins/iso/iso.c#L100 'du -c -k -s' works on FreeBSD which doesn't have GNU coreutils. (However I agree it's not very natural to use this plugin with FreeBSD at all.) The return from 'chdir (origdir)' is checked on the normal path, and not checked only on the error path where we're only trying to make a best effort clean-up. Rich.
2019 Feb 19
7
[PATCH nbdkit 0/4] New plugin: Add linuxdisk plugin.
Turns out Japanese trains are good for coding! In supermin we have a bunch of code to create the libguestfs appliance. It creates it directly using libext2fs (part of e2fsprogs). We can use the same technique to create ext2 virtual disks in nbdkit, which is what this new plugin does. Why a new plugin instead of modifying the floppy plugin? See the 4/4 commit message for an explanation. The
2020 Feb 25
6
[PATCH nbdkit 0/5] server: Add .get_ready callback.
I like this change. I think we were overloading the config_complete method before to do two different things (complete configuration; do any allocation/housekeeping necessary before we can start serving). The only questions in my mind are whether we want this before 1.18, and whether the name ("get_ready") is a good one. Rich.
2019 Feb 19
2
Re: [PATCH nbdkit 4/4] Add linuxdisk plugin.
...st char *dir, ext2_filsys fs, ext2_ino_t dir_ino, > + struct file **files, size_t *nr_files) > +{ > + error2: > + closedir (DIR); > + error1: > + err = errno; > +#pragma GCC diagnostic push > +#pragma GCC diagnostic ignored "-Wunused-result" > + chdir (origdir); > +#pragma GCC diagnostic pop Failure to return to the original directory may cause the rest of nbdkit to misbehave, shouldn't we check the result after all and exit on error? > + > +/* To identify hard links we sort the files array by device and inode > + * number (thus hard li...