[yast-commit] r40959 - in /trunk/storage: libstorage/src/LoopCo.h libstorage/src/Volume.cc libstorage/src/Volume.h package/yast2-storage.changes
Author: fehr Date: Tue Sep 18 18:27:21 2007 New Revision: 40959 URL: http://svn.opensuse.org/viewcvs/yast?rev=40959&view=rev Log: fix wrong cryptotab line for old style encryption (#325597) Modified: trunk/storage/libstorage/src/LoopCo.h trunk/storage/libstorage/src/Volume.cc trunk/storage/libstorage/src/Volume.h trunk/storage/package/yast2-storage.changes Modified: trunk/storage/libstorage/src/LoopCo.h URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/libstorage/src/LoopCo.h?rev=40959&r1=40958&r2=40959&view=diff ============================================================================== --- trunk/storage/libstorage/src/LoopCo.h (original) +++ trunk/storage/libstorage/src/LoopCo.h Tue Sep 18 18:27:21 2007 @@ -90,7 +90,6 @@ bool findLoopDev( const string& dev, LoopIter& i ); void addLoop( Loop* m ); void updateEntry( const Loop* m ); - static int getFreeLoop( string& dev ); void init(); Modified: trunk/storage/libstorage/src/Volume.cc URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/libstorage/src/Volume.cc?rev=40959&r1=40958&r2=40959&view=diff ============================================================================== --- trunk/storage/libstorage/src/Volume.cc (original) +++ trunk/storage/libstorage/src/Volume.cc Tue Sep 18 18:27:21 2007 @@ -2268,7 +2268,7 @@ if( cont->type()!=LOOP ) { if( dmcrypt() ) - ret = optNoauto()?dev:dmcrypt_dev; + ret = (inCryptotab()||optNoauto())?dev:dmcrypt_dev; else ret = getMountByString( mount_by, dev, uuid, label ); } @@ -2414,8 +2414,11 @@ { changed = true; che.encr = encryption; - if( !dmcrypt() ) + if( inCryptotab() ) + { + getFreeLoop(); che.loop_dev = fstab_loop_dev; + } che.dentry = de; if( encryption!=ENC_NONE ) che.freq = che.passno = 0; @@ -2448,8 +2451,11 @@ che.encr = encryption; if( dmcrypt() && isTmpCryptMp(mp) && crypt_pwd.empty() ) che.tmpcrypt = true; - if( !dmcrypt() ) + if( inCryptotab() ) + { + getFreeLoop(); che.loop_dev = fstab_loop_dev; + } che.fs = fs_names[fs]; getFstabOpts( che.opts ); che.mount = mp; Modified: trunk/storage/libstorage/src/Volume.h URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/libstorage/src/Volume.h?rev=40959&r1=40958&r2=40959&view=diff ============================================================================== --- trunk/storage/libstorage/src/Volume.h (original) +++ trunk/storage/libstorage/src/Volume.h Tue Sep 18 18:27:21 2007 @@ -157,7 +157,7 @@ string sizeString() const; string bootMount() const; bool optNoauto() const; - bool inCryptotab() const { return( encryption!=ENC_LUKS && is_loop && !optNoauto() ); } + bool inCryptotab() const { return( encryption!=ENC_LUKS && !optNoauto() ); } bool inCrypttab() const { return( encryption==ENC_LUKS && !optNoauto() ); } virtual void print( std::ostream& s ) const { s << *this; } int getFreeLoop(); Modified: trunk/storage/package/yast2-storage.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/storage/package/yast2-storage.changes?rev=40959&r1=40958&r2=40959&view=diff ============================================================================== --- trunk/storage/package/yast2-storage.changes (original) +++ trunk/storage/package/yast2-storage.changes Tue Sep 18 18:27:21 2007 @@ -1,4 +1,9 @@ ------------------------------------------------------------------- +Tue Sep 18 18:22:57 CEST 2007 - fehr@suse.de + +- fix wrong cryptotab line for old style encryption (#325597) + +------------------------------------------------------------------- Mon Sep 17 14:26:39 CEST 2007 - fehr@suse.de - version 2.15.24 -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
fehr@svn.opensuse.org