[prev in list] [next in list] [prev in thread] [next in thread] 

List:       intermezzo-cvs
Subject:    CVS: intermezzo/presto cache.c,1.14.2.4,1.14.2.5 file.c,1.17.2.12,1.17.2.13
From:       "Peter J. Braam" <braam () users ! sourceforge ! net>
Date:       2001-04-30 18:15:58
[Download RAW message or body]

Update of /cvsroot/intermezzo/intermezzo/presto
In directory usw-pr-cvs1:/tmp/cvs-serv9902

Modified Files:
      Tag: b1_0_0
	cache.c file.c 
Log Message:
changes for the srv.us.mvd space bug -- a completely different bug from the
one I found on Saturday. 


Index: cache.c
===================================================================
RCS file: /cvsroot/intermezzo/intermezzo/presto/cache.c,v
retrieving revision 1.14.2.4
retrieving revision 1.14.2.5
diff -U2 -r1.14.2.4 -r1.14.2.5
--- cache.c	2001/04/18 16:55:26	1.14.2.4
+++ cache.c	2001/04/30 18:15:55	1.14.2.5
@@ -215,8 +215,8 @@
 }
 
-int presto_reserve_space(struct presto_cache *cache, int req)
+int presto_reserve_space(struct presto_cache *cache, loff_t req)
 {
         struct filter_fs *filter; 
-        unsigned long avail; 
+        loff_t avail; 
 	struct super_block *sb = cache->cache_mtde->d_inode->i_sb;
 
@@ -239,5 +239,5 @@
 }
 
-void presto_release_space(struct presto_cache *cache, int req)
+void presto_release_space(struct presto_cache *cache, loff_t req)
 {
         CDEBUG(D_SUPER, "ESC::%ld ---> %ld \n", (long) cache->cache_reserved,

Index: file.c
===================================================================
RCS file: /cvsroot/intermezzo/intermezzo/presto/file.c,v
retrieving revision 1.17.2.12
retrieving revision 1.17.2.13
diff -U2 -r1.17.2.12 -r1.17.2.13
--- file.c	2001/04/18 11:52:07	1.17.2.12
+++ file.c	2001/04/30 18:15:55	1.17.2.13
@@ -287,4 +287,5 @@
 
 	error = presto_reserve_space(fset->fset_cache, res_size); 
+	CDEBUG(D_INODE, "Reserved %ld for %ld\n", res_size, size); 
         if ( error ) { 
                 EXIT;
@@ -328,16 +329,14 @@
                 res = presto_journal_write(&rec, fset, file);
                 fdata->fd_lml_offset = rec.offset;
+		if ( res ) {
+			/* XXX oops here to get this bug */ 
+			/* *(int *)0 = 1; */
+			EXIT;
+			goto exit_write;
+		}
+		
+		presto_trans_commit(fset, handle);
         }
-        
-        if ( res ) {
-                /* XXX oops here to get this bug */ 
-                /* *(int *)0 = 1; */
-                EXIT;
-		goto exit_write;
-        }
 
-        if (do_lml_here) {
-                presto_trans_commit(fset, handle);
-        }
         fops = filter_c2cffops(cache->cache_filter);
         res = fops->write(file, buf, size, off);


_______________________________________________
intermezzo-commit mailing list
intermezzo-commit@lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/intermezzo-commit

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic