diff options
author | cinap_lenrek <cinap_lenrek@felloff.net> | 2014-08-09 17:37:02 +0200 |
---|---|---|
committer | cinap_lenrek <cinap_lenrek@felloff.net> | 2014-08-09 17:37:02 +0200 |
commit | 760063ab57aa42ea82f1bf5c9177c0cde206aeee (patch) | |
tree | 611a4d90579e9e5024540e2af85e918df0257c88 /sys/src/cmd/cwfs/mworm.c | |
parent | 3472f91129a7a594b356f9a22af2a8176f6e4b1c (diff) |
cwfs: fix 32bit multiplication overflows for allocation sizes (thanks kenji okomoto)
Diffstat (limited to 'sys/src/cmd/cwfs/mworm.c')
-rw-r--r-- | sys/src/cmd/cwfs/mworm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/cmd/cwfs/mworm.c b/sys/src/cmd/cwfs/mworm.c index b4d444236..14e9dea5b 100644 --- a/sys/src/cmd/cwfs/mworm.c +++ b/sys/src/cmd/cwfs/mworm.c @@ -14,7 +14,7 @@ mcatinit(Device *d) d->cat.ndev++; } - list = ialloc(d->cat.ndev * sizeof(Device*), 0); + list = ialloc((uintptr)d->cat.ndev * sizeof(Device*), 0); d->private = list; for(x=d->cat.first; x; x=x->link) { *list++ = x; |