Fix incorrect paths for debug files.
This commit is contained in:
12
Streams.cpp
12
Streams.cpp
@@ -54,7 +54,7 @@ shared_ptr<int> getHostDescriptor() {
|
|||||||
#ifdef DEBUG_STREAMS
|
#ifdef DEBUG_STREAMS
|
||||||
|
|
||||||
shared_ptr<FILE> getComHostStream() {
|
shared_ptr<FILE> getComHostStream() {
|
||||||
static shared_ptr<FILE> stream{ fopen((cacheDirectory + "comhost.txt").c_str(), "wb"),
|
static shared_ptr<FILE> stream{ fopen((cacheDirectory + "/comhost.txt").c_str(), "wb"),
|
||||||
[](FILE* f) {
|
[](FILE* f) {
|
||||||
clog << "Closing comhost stream" << endl;
|
clog << "Closing comhost stream" << endl;
|
||||||
fclose(f);
|
fclose(f);
|
||||||
@@ -68,7 +68,7 @@ shared_ptr<FILE> getComHostStream() {
|
|||||||
|
|
||||||
shared_ptr<FILE> getHostPacketStream() {
|
shared_ptr<FILE> getHostPacketStream() {
|
||||||
static shared_ptr<FILE> stream{
|
static shared_ptr<FILE> stream{
|
||||||
initHTML(fopen((cacheDirectory + "hostpackets.html").c_str(), "wb"), "Host Packets"),
|
initHTML(fopen((cacheDirectory + "/hostpackets.html").c_str(), "wb"), "Host Packets"),
|
||||||
[](FILE* f) {
|
[](FILE* f) {
|
||||||
clog << "Closing hostPackets stream" << endl;
|
clog << "Closing hostPackets stream" << endl;
|
||||||
closeHTML(f);
|
closeHTML(f);
|
||||||
@@ -83,7 +83,7 @@ shared_ptr<FILE> getHostPacketStream() {
|
|||||||
|
|
||||||
shared_ptr<FILE> getHostAPDUStream() {
|
shared_ptr<FILE> getHostAPDUStream() {
|
||||||
static shared_ptr<FILE> stream{
|
static shared_ptr<FILE> stream{
|
||||||
initHTML(fopen((cacheDirectory + "hostAPDU.html").c_str(), "wb"), "Host APDU"),
|
initHTML(fopen((cacheDirectory + "/hostAPDU.html").c_str(), "wb"), "Host APDU"),
|
||||||
[](FILE* f) {
|
[](FILE* f) {
|
||||||
clog << "Closing host APDU stream" << endl;
|
clog << "Closing host APDU stream" << endl;
|
||||||
closeHTML(f);
|
closeHTML(f);
|
||||||
@@ -97,7 +97,7 @@ shared_ptr<FILE> getHostAPDUStream() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
shared_ptr<FILE> getComDevStream() {
|
shared_ptr<FILE> getComDevStream() {
|
||||||
static shared_ptr<FILE> stream{ fopen((cacheDirectory + "comdev.txt").c_str(), "wb"),
|
static shared_ptr<FILE> stream{ fopen((cacheDirectory + "/comdev.txt").c_str(), "wb"),
|
||||||
[](FILE* f) {
|
[](FILE* f) {
|
||||||
clog << "Closing comdev stream" << endl;
|
clog << "Closing comdev stream" << endl;
|
||||||
fclose(f);
|
fclose(f);
|
||||||
@@ -111,7 +111,7 @@ shared_ptr<FILE> getComDevStream() {
|
|||||||
|
|
||||||
shared_ptr<FILE> getDevPacketStream() {
|
shared_ptr<FILE> getDevPacketStream() {
|
||||||
static shared_ptr<FILE> stream{
|
static shared_ptr<FILE> stream{
|
||||||
initHTML(fopen((cacheDirectory + "devpackets.html").c_str(), "wb"), "Dev Packets"),
|
initHTML(fopen((cacheDirectory + "/devpackets.html").c_str(), "wb"), "Dev Packets"),
|
||||||
[](FILE* f) {
|
[](FILE* f) {
|
||||||
clog << "Closing devPackets stream" << endl;
|
clog << "Closing devPackets stream" << endl;
|
||||||
closeHTML(f);
|
closeHTML(f);
|
||||||
@@ -125,7 +125,7 @@ shared_ptr<FILE> getDevPacketStream() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
shared_ptr<FILE> getDevAPDUStream() {
|
shared_ptr<FILE> getDevAPDUStream() {
|
||||||
static shared_ptr<FILE> stream{ initHTML(fopen((cacheDirectory + "devAPDU.html").c_str(), "wb"),
|
static shared_ptr<FILE> stream{ initHTML(fopen((cacheDirectory + "/devAPDU.html").c_str(), "wb"),
|
||||||
"Dev APDU"),
|
"Dev APDU"),
|
||||||
[](FILE* f) {
|
[](FILE* f) {
|
||||||
clog << "Closing dev APDU stream" << endl;
|
clog << "Closing dev APDU stream" << endl;
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|||||||
# define STORAGE_PREFIX "/sdcard/U2F/"
|
# define STORAGE_PREFIX "/sdcard/U2F/"
|
||||||
extern std::string hidDev;
|
extern std::string hidDev;
|
||||||
# define HID_DEV hidDev.c_str()
|
# define HID_DEV hidDev.c_str()
|
||||||
# define DEBUG_STREAMS "/sdcard/log/"
|
# define DEBUG_STREAMS "/sdcard/log"
|
||||||
# define HID_SOCKET
|
# define HID_SOCKET
|
||||||
// #define DEBUG_MSGS
|
// #define DEBUG_MSGS
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user