Cast byte_array to vector<char>.