Skip to content

Commit

Permalink
Trying to fix travis
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan Kürzeder committed Jul 22, 2019
1 parent 43ffcdb commit 047a81c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
language: cpp
dist: bionic
matrix:
include:
- compiler: gcc
Expand All @@ -9,6 +10,7 @@ matrix:
packages:
- g++-8
- libssl-dev
- libcrypto++-dev
env: ENV_CXX=g++-8 ENV_CC=gcc-8
before_script:
- wget https://github.com/sbx320/premake5-travis/blob/master/premake5?raw=true -O
Expand Down
4 changes: 2 additions & 2 deletions module/CFunctions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ int CFunctions::sign_jwt_token(lua_State* lua_vm)
return 1;
}

const auto result = Utils::parse_named_table(lua_vm, 1);
const auto claims = Utils::parse_named_table(lua_vm, 1);
const auto algorithm = lua_tostring(lua_vm, 2);
const auto secret = lua_tostring(lua_vm, 3);

Expand All @@ -31,7 +31,7 @@ int CFunctions::sign_jwt_token(lua_State* lua_vm)
.set_not_before(now);

// Add claims
for (const auto& pair : result)
for (const auto& pair : claims)
{
jwt.set_payload_claim(pair.first, pair.second);
}
Expand Down
7 changes: 2 additions & 5 deletions module/UItils.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,7 @@
#include <unordered_map>
#include <ostream>
#include <iostream>

struct lua_State;

extern ILuaModuleManager10* pModuleManager;
#include "CFunctions.h"

class Utils
{
Expand All @@ -21,7 +18,7 @@ class Utils
if (lua_type(lua_vm, -1) != LUA_TSTRING || lua_type(lua_vm, -2) != LUA_TSTRING)
{
stringstream ss;
ss << "Bad Argument @ parse_named_table. Got invalid table entry, expect key(string) and value(string), but was key(" << lua_typename(lua_vm, lua_type(lua_vm, -2)) << ") and value(" << lua_typename(lua_vm, lua_type(lua_vm, -1)) << "). Skipping...";
ss << "Bad Argument @ parse_named_table. Got invalid table entry, expected key(string) and value(string), but was key(" << lua_typename(lua_vm, lua_type(lua_vm, -2)) << ") and value(" << lua_typename(lua_vm, lua_type(lua_vm, -1)) << "). Skipping...";
pModuleManager->ErrorPrintf(ss.str().c_str());
lua_error(lua_vm);
break;
Expand Down
1 change: 0 additions & 1 deletion premake5.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,4 @@ solution "JWT"
optimize "On"

include "module"
-- include "pathfind"
include "test"

0 comments on commit 047a81c

Please sign in to comment.