summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2007-10-12 18:13:30 (GMT)
committerH. Peter Anvin <hpa@zytor.com>2007-10-12 18:13:30 (GMT)
commitaf2d5350b18140f7c3cf16e09c660f49f083bc3f (patch)
tree6a19c8eb5fb8db9c0ea9d062c755a84a81d3af1a
parent32367802a06117aa8c30762ea4e24b449891b3d0 (diff)
downloadpbn-af2d5350b18140f7c3cf16e09c660f49f083bc3f.zip
pbn-af2d5350b18140f7c3cf16e09c660f49f083bc3f.tar.gz
pbn-af2d5350b18140f7c3cf16e09c660f49f083bc3f.tar.bz2
pbn-af2d5350b18140f7c3cf16e09c660f49f083bc3f.tar.xz
Fix pbn_shr()/pbn_shl()
Silly typos in the shift functions
-rw-r--r--pbn_shift.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/pbn_shift.c b/pbn_shift.c
index 67a78ce..e80cb24 100644
--- a/pbn_shift.c
+++ b/pbn_shift.c
@@ -23,6 +23,7 @@ struct pbn *pbn_shl(struct pbn *src, int shift)
pbn_atom_t b, c;
int i;
int sw, sb;
+ struct pbn *dst;
if (src->bits == 0 || shift == 0)
return src; /* Source was zero or shift was zero */
@@ -33,7 +34,7 @@ struct pbn *pbn_shl(struct pbn *src, int shift)
bits = src->bits + shift;
len = (bits+PBN_ATOM_BITS-1)/PBN_ATOM_BITS;
- dst = src_cow(src, len);
+ dst = pbn_cow(src, len);
sw = shift / PBN_ATOM_BITS;
sb = shift % PBN_ATOM_BITS;
@@ -64,6 +65,7 @@ struct pbn *pbn_shr(struct pbn *src, int shift)
pbn_atom_t b, c;
int i;
int sw, sb;
+ struct pbn *dst;
if (src->bits == 0 || shift == 0)
return src; /* Source was zero or shift was zero */
@@ -72,7 +74,7 @@ struct pbn *pbn_shr(struct pbn *src, int shift)
return pbn_shl(src, -shift);
len = src->len;
- dst = src_cow(src, len); /* Leave at its old size */
+ dst = pbn_cow(src, len); /* Leave at its old size */
sw = shift / PBN_ATOM_BITS;
sb = shift % PBN_ATOM_BITS;