aboutsummaryrefslogtreecommitdiffstats
path: root/bruiser/bruiser.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--bruiser/bruiser.cpp20
1 files changed, 17 insertions, 3 deletions
diff --git a/bruiser/bruiser.cpp b/bruiser/bruiser.cpp
index 324841d..8934867 100644
--- a/bruiser/bruiser.cpp
+++ b/bruiser/bruiser.cpp
@@ -299,7 +299,7 @@ class PyExec {
PRINT_WITH_COLOR_LB(YELLOW, "functions with a zero size will not be printed:");
for (auto &iter : hexobj) {
for (auto &iterer : iter) {
- std::cout << RED << int(iterer) << " ";
+ std::cout << RED << std::hex << int(iterer) << " ";
}
std::cout << "\n" << NORMAL;
}
@@ -1588,8 +1588,7 @@ class LuaWrapper
unsigned int returncount = 0;
for (auto &iter : ShellGlobalInstance.PATH)
- {
- lua_pushstring(__ls, iter.c_str());
+ { lua_pushstring(__ls, iter.c_str());
std::cout << BLUE << iter.c_str() << NORMAL << "\n";
returncount++;
}
@@ -1611,6 +1610,21 @@ class LuaWrapper
return returncount;
}
+ int BruiserLuaCallXFunc(lua_State* __ls) {
+ int numargs = lua_gettop(__ls);
+ std::string argtype;
+
+ if (numargs % 2 != 0) {
+ PRINT_WITH_COLOR_LB(RED, "Each arg should be accompanied with its type.");
+ }
+
+ for (int i = 0; i < numargs; i = i + 2) {
+ argtype = lua_tostring(__ls, i);
+ }
+
+ return 0;
+ }
+
int BruiserLuaChangeDirectory(lua_State* __ls)
{
int numargs = lua_gettop(__ls);