buf_size: fix type_bytes()
Ugh... I'm not totally sure this is correct. It seems to work but I can't
swear that I haven't missed something.
Anyway, this patch fixes commit
1ce2e2a68fe9 ("type: fix type_bits() for
arrays. The problem is if you pass an array to a function then you want
to say that the array is a pointer in the valid range. But if you want
to get the size of the array then maybe you want the whole size... I've
introduced a array_size() to give you that.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>