This is a static archive of our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

Relative file paths in Lua scripts?

0

I have a directory containing my dissector, listener, and subdirectories with libraries. I've been attempting to use dofile, require, and filepath strings to call the libraries along with additional files like so:

dofile("subdirec/script.lua")

require "subdirec.script"

local filename = "subdirec/file.xml"

However, when I attempt using this syntax and open Wireshark I get the “file does not exist error”.

asked 09 May ‘17, 15:54

Irfan%20Hossain's gravatar image

Irfan Hossain
116611
accept rate: 0%