Files
shaka-packager/packager/utils/hex_parser.h
Niklas Korz 27a1d71e3d
Some checks failed
Update Issues / update-issues (push) Has been cancelled
Release / Settings (push) Has been cancelled
Release / release (push) Has been cancelled
Release / Compute latest release flag (push) Has been cancelled
Release / Update docs (push) Has been cancelled
Release / Build (push) Has been cancelled
Release / Update docker image (push) Has been cancelled
Release / Artifacts (push) Has been cancelled
Release / Update NPM (push) Has been cancelled
fix(deps): update abseil-cpp to 20260107.1, protobuf to 33.5 (#1553)
All deprecations have been addressed in this PR and Protobuf has been
updated to 33.5 as older versions lead to build failures on Linux with
this abseil-cpp version.
2026-03-17 20:48:13 -07:00

26 lines
798 B
C++

// Copyright 2022 Google LLC. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
// https://developers.google.com/open-source/licenses/bsd
#ifndef PACKAGER_UTILS_HEX_PARSER_H_
#define PACKAGER_UTILS_HEX_PARSER_H_
#include <cstdint>
#include <string>
#include <vector>
namespace shaka {
// If you use absl::HexStringToBytes directly, any invalid byte sequence will
// be converted into NUL characters silently. This function will validate the
// input.
bool ValidHexStringToBytes(const std::string& hex, std::string* bytes);
// same but output to a vector of uint8_t
bool ValidHexStringToBytes(const std::string& hex, std::vector<uint8_t>* bytes);
} // namespace shaka
#endif // PACKAGER_UTILS_HEX_PARSER_H_