eina: handle properly case where str != NULL and slen == 0