gvariant: fix recursing into empty array
In GVariant, arrays of variable size values have offsets at the end.
We need to know how many offsets are in an array when we recurse
into it. To count the offsets we need to have offsets size and
the start and end of the offsets. The start of the offsets
is computed from the value of the last offset.
On the other hand, empty arrays have size equal to zero. In other words,
they have no offsets. Function _dbus_reader_count_array_elems missed it.
This commit fixes _dbus_reader_count_array_elems() by ensuring returning 0
when an array is empty.
Change-Id: I5f93ea89e490b321b2c2528e7bae838a1af0ec75