Remove trailing white space with:

for f in *.{h,c}; do sed -i .sed 's/[[:blank:]]*$//' $f; done
(Thanks to Nicolás Wolovick)
This commit is contained in:
Frans Kaashoek 2016-08-25 09:13:00 -04:00
parent 6de6a3c952
commit 7894fcd217
32 changed files with 116 additions and 116 deletions

14
fs.c
View file

@ -5,7 +5,7 @@
// + Directories: inode with special contents (list of other inodes!)
// + Names: paths like /usr/rtm/xv6/fs.c for convenient naming.
//
// This file contains the low-level file system manipulation
// This file contains the low-level file system manipulation
// routines. The (higher-level) system call implementations
// are in sysfile.c.
@ -29,7 +29,7 @@ void
readsb(int dev, struct superblock *sb)
{
struct buf *bp;
bp = bread(dev, 1);
memmove(sb, bp->data, sizeof(*sb));
brelse(bp);
@ -40,14 +40,14 @@ static void
bzero(int dev, int bno)
{
struct buf *bp;
bp = bread(dev, bno);
memset(bp->data, 0, BSIZE);
log_write(bp);
brelse(bp);
}
// Blocks.
// Blocks.
// Allocate a zeroed disk block.
static uint
@ -348,7 +348,7 @@ iunlockput(struct inode *ip)
//
// The content (data) associated with each inode is stored
// in blocks on the disk. The first NDIRECT block numbers
// are listed in ip->addrs[]. The next NINDIRECT blocks are
// are listed in ip->addrs[]. The next NINDIRECT blocks are
// listed in block ip->addrs[NDIRECT].
// Return the disk block address of the nth block in inode ip.
@ -401,7 +401,7 @@ itrunc(struct inode *ip)
ip->addrs[i] = 0;
}
}
if(ip->addrs[NDIRECT]){
bp = bread(ip->dev, ip->addrs[NDIRECT]);
a = (uint*)bp->data;
@ -554,7 +554,7 @@ dirlink(struct inode *dp, char *name, uint inum)
de.inum = inum;
if(writei(dp, (char*)&de, off, sizeof(de)) != sizeof(de))
panic("dirlink");
return 0;
}