"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "cryptmount.c" between
cryptmount-5.3.1.tar.gz and cryptmount-5.3.2.tar.gz

About: cryptmount allows any user to access encrypted filing systems on demand under GNU/Linux systems. It also assists the system administrator in creating and managing encrypted filesystems based on the kernels dm-crypt device-mapper target.

cryptmount.c  (cryptmount-5.3.1):cryptmount.c  (cryptmount-5.3.2)
skipping to change at line 447 skipping to change at line 447
killloop = 1; killloop = 1;
goto bail_out; goto bail_out;
} }
if (mntdev != NULL) { if (mntdev != NULL) {
devmap_path(mntdev, tgt->ident); devmap_path(mntdev, tgt->ident);
} }
bail_out: bail_out:
if (killloop) unblockify_file(&tgtdev, isloop); /* mounting failed? */ if (killloop) unblockify_file(&tgtdev, isloop); /* mounting failed? */
if (tgtdev) free((void*)tgtdev);
sec_free(dmparams); sec_free(dmparams);
sec_free(key); sec_free(key);
return eflag; return eflag;
} /* do_devsetup() */ } /* do_devsetup() */
/*! @brief Remove all devices attached to encrypted target /*! @brief Remove all devices attached to encrypted target
* *
* This will close-down device-mapper and loopback devices * This will close-down device-mapper and loopback devices
* configured by do_setup(). * configured by do_setup().
skipping to change at line 579 skipping to change at line 580
* *
* This provides the back-end functionality for * This provides the back-end functionality for
* the '--unmount' command-line option. * the '--unmount' command-line option.
* *
* \see do_mount(), do_devshutdown(), fs_unmount(). * \see do_mount(), do_devshutdown(), fs_unmount().
*/ */
static int do_unmount(const bound_tgtdefn_t *boundtgt) static int do_unmount(const bound_tgtdefn_t *boundtgt)
{ const tgtdefn_t *tgt = boundtgt->tgt; { const tgtdefn_t *tgt = boundtgt->tgt;
int eflag=ERR_NOERROR; int eflag=ERR_NOERROR;
struct passwd *pwent; struct passwd *pwent;
char *mntdev=NULL; char *mntdev = NULL;
tgtstat_t *tstat; tgtstat_t *tstat = NULL;
/* Check if filing system has been configured at all: */ /* Check if filing system has been configured at all: */
if (!is_mounted(tgt) || (tstat = get_tgtstatus(tgt)) == NULL) { if (!is_mounted(tgt) || (tstat = get_tgtstatus(tgt)) == NULL) {
fprintf(stderr, _("Target \"%s\" does not appear to be mounted\n"), fprintf(stderr, _("Target \"%s\" does not appear to be mounted\n"),
tgt->ident); tgt->ident);
eflag = WRN_UNCONFIG; eflag = WRN_UNCONFIG;
goto bail_out; goto bail_out;
} }
/* Check if filing system has been mounted & locked by another user: */ /* Check if filing system has been mounted & locked by another user: */
skipping to change at line 622 skipping to change at line 623
put_tgtstatus(tgt, NULL); put_tgtstatus(tgt, NULL);
/* Remove supporting device-mapper target etc */ /* Remove supporting device-mapper target etc */
if (do_devshutdown(boundtgt) != ERR_NOERROR) { if (do_devshutdown(boundtgt) != ERR_NOERROR) {
eflag = ERR_BADDEVICE; eflag = ERR_BADDEVICE;
} }
bail_out: bail_out:
if (mntdev != NULL) free((void*)mntdev); if (mntdev != NULL) free((void*)mntdev);
if (tstat != NULL) free_tgtstatus(tstat);
return eflag; return eflag;
} }
/*! @brief Setup an encrypted swap partition /*! @brief Setup an encrypted swap partition
* *
* This provides the back-end functionality for * This provides the back-end functionality for
* the '--swapon' command-line option. * the '--swapon' command-line option.
* *
* \see do_swapoff(), do_devsetup(), fs_swapon(). * \see do_swapoff(), do_devsetup(), fs_swapon().
 End of changes. 3 change blocks. 
2 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)