Version 17 plus test updates and OPK v17
This is the first public release of OPK v17. See the file CHANGELOG.md for details.
This commit is contained in:
@@ -22,13 +22,13 @@ namespace wvutil {
|
||||
typedef enum {
|
||||
// This log level should only be used for |g_cutoff|, in order to silence all
|
||||
// logging. It should never be passed to |Log()| as a log level.
|
||||
LOG_SILENT = -1,
|
||||
CDM_LOG_SILENT = -1,
|
||||
|
||||
LOG_ERROR = 0,
|
||||
LOG_WARN = 1,
|
||||
LOG_INFO = 2,
|
||||
LOG_DEBUG = 3,
|
||||
LOG_VERBOSE = 4,
|
||||
CDM_LOG_ERROR = 0,
|
||||
CDM_LOG_WARN = 1,
|
||||
CDM_LOG_INFO = 2,
|
||||
CDM_LOG_DEBUG = 3,
|
||||
CDM_LOG_VERBOSE = 4,
|
||||
} LogPriority;
|
||||
|
||||
extern LogPriority g_cutoff;
|
||||
@@ -53,7 +53,7 @@ class LogBuffer {
|
||||
|
||||
extern LogBuffer g_logbuf;
|
||||
|
||||
static const uint32_t UNKNOWN_UID = ~0;
|
||||
static const uint32_t UNKNOWN_UID = std::numeric_limits<uint32_t>::max();
|
||||
|
||||
#ifdef __ANDROID__
|
||||
void SetLoggingUid(const uint32_t);
|
||||
@@ -93,15 +93,15 @@ CORE_UTIL_EXPORT void Log(const char* file, const char* function, int line,
|
||||
// Log APIs
|
||||
#ifndef LOGE
|
||||
# define LOGE(...) \
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::LOG_ERROR, __VA_ARGS__)
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::CDM_LOG_ERROR, __VA_ARGS__)
|
||||
# define LOGW(...) \
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::LOG_WARN, __VA_ARGS__)
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::CDM_LOG_WARN, __VA_ARGS__)
|
||||
# define LOGI(...) \
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::LOG_INFO, __VA_ARGS__)
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::CDM_LOG_INFO, __VA_ARGS__)
|
||||
# define LOGD(...) \
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::LOG_DEBUG, __VA_ARGS__)
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::CDM_LOG_DEBUG, __VA_ARGS__)
|
||||
# define LOGV(...) \
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::LOG_VERBOSE, __VA_ARGS__)
|
||||
Log(__FILE__, __func__, __LINE__, wvutil::CDM_LOG_VERBOSE, __VA_ARGS__)
|
||||
#endif
|
||||
} // namespace wvutil
|
||||
|
||||
|
||||
@@ -20,10 +20,15 @@ CORE_UTIL_EXPORT std::vector<uint8_t> a2b_hex(const std::string& label,
|
||||
const std::string& b);
|
||||
CORE_UTIL_EXPORT std::string a2bs_hex(const std::string& b);
|
||||
|
||||
// Binary to ASCII hex conversion.
|
||||
// Binary to ASCII hex conversion. The default versions limit output to 2k to
|
||||
// protect us from log spam. The unlimited version has no length limit.
|
||||
CORE_UTIL_EXPORT std::string b2a_hex(const std::vector<uint8_t>& b);
|
||||
CORE_UTIL_EXPORT std::string unlimited_b2a_hex(const std::vector<uint8_t>& b);
|
||||
CORE_UTIL_EXPORT std::string b2a_hex(const std::string& b);
|
||||
CORE_UTIL_EXPORT std::string unlimited_b2a_hex(const std::string& b);
|
||||
CORE_UTIL_EXPORT std::string HexEncode(const uint8_t* bytes, size_t size);
|
||||
CORE_UTIL_EXPORT std::string UnlimitedHexEncode(const uint8_t* bytes,
|
||||
size_t size);
|
||||
|
||||
// Base64 encoding/decoding.
|
||||
// Converts binary data into the ASCII Base64 character set and vice
|
||||
|
||||
Reference in New Issue
Block a user