commit
10337fcefc
3 changed files with 4 additions and 3 deletions
|
@ -6,7 +6,7 @@ cmake_minimum_required (VERSION 2.8.11)
|
||||||
project (cpp-jwt)
|
project (cpp-jwt)
|
||||||
|
|
||||||
#SET (CMAKE_CXX_COMPILER /usr/local/bin/g++)
|
#SET (CMAKE_CXX_COMPILER /usr/local/bin/g++)
|
||||||
SET( CMAKE_CXX_FLAGS "-std=c++14 -Wall" )
|
SET( CMAKE_CXX_FLAGS "-std=c++14 -Wall -Wextra" )
|
||||||
|
|
||||||
include_directories (include)
|
include_directories (include)
|
||||||
|
|
||||||
|
|
|
@ -229,16 +229,16 @@ inline std::string base64_decode(const char* in, size_t len)
|
||||||
const auto fourth = dmap.at(in[3]);
|
const auto fourth = dmap.at(in[3]);
|
||||||
result[i + 2] = (third << 6) | fourth;
|
result[i + 2] = (third << 6) | fourth;
|
||||||
bytes_wr++;
|
bytes_wr++;
|
||||||
//FALLTHROUGH
|
|
||||||
}
|
}
|
||||||
|
//FALLTHROUGH
|
||||||
case 3:
|
case 3:
|
||||||
{
|
{
|
||||||
const auto second = dmap.at(in[1]);
|
const auto second = dmap.at(in[1]);
|
||||||
const auto third = dmap.at(in[2]);
|
const auto third = dmap.at(in[2]);
|
||||||
result[i + 1] = (second << 4) | (third >> 2);
|
result[i + 1] = (second << 4) | (third >> 2);
|
||||||
bytes_wr++;
|
bytes_wr++;
|
||||||
//FALLTHROUGH
|
|
||||||
}
|
}
|
||||||
|
//FALLTHROUGH
|
||||||
case 2:
|
case 2:
|
||||||
{
|
{
|
||||||
const auto first = dmap.at(in[0]);
|
const auto first = dmap.at(in[0]);
|
||||||
|
|
|
@ -607,6 +607,7 @@ void jwt_object::set_decode_params(DecodeParams& dparams, params::detail::valida
|
||||||
template <typename DecodeParams>
|
template <typename DecodeParams>
|
||||||
void jwt_object::set_decode_params(DecodeParams& dparams)
|
void jwt_object::set_decode_params(DecodeParams& dparams)
|
||||||
{
|
{
|
||||||
|
(void) dparams; // prevent -Wunused-parameter with gcc
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue