mirror of
https://github.com/VectorCamp/vectorscan.git
synced 2025-06-28 16:41:01 +03:00
castle_dump: use StdioFile
This commit is contained in:
parent
31a445a0e8
commit
a18fbfe873
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2015-2016, Intel Corporation
|
* Copyright (c) 2015-2017, Intel Corporation
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
* modification, are permitted provided that the following conditions are met:
|
* modification, are permitted provided that the following conditions are met:
|
||||||
@ -71,7 +71,7 @@ void dumpTextSubCastle(const SubCastle &sub, FILE *f) {
|
|||||||
void nfaExecCastle_dump(const struct NFA *nfa, const string &base) {
|
void nfaExecCastle_dump(const struct NFA *nfa, const string &base) {
|
||||||
const Castle *c = (const Castle *)getImplNfa(nfa);
|
const Castle *c = (const Castle *)getImplNfa(nfa);
|
||||||
|
|
||||||
FILE *f = fopen_or_throw((base + ".txt").c_str(), "w");
|
StdioFile f(base + ".txt", "w");
|
||||||
|
|
||||||
fprintf(f, "Castle multi-tenant repeat engine\n");
|
fprintf(f, "Castle multi-tenant repeat engine\n");
|
||||||
fprintf(f, "\n");
|
fprintf(f, "\n");
|
||||||
@ -117,7 +117,6 @@ void nfaExecCastle_dump(const struct NFA *nfa, const string &base) {
|
|||||||
fprintf(f, "Sub %u:\n", i);
|
fprintf(f, "Sub %u:\n", i);
|
||||||
dumpTextSubCastle(sub[i], f);
|
dumpTextSubCastle(sub[i], f);
|
||||||
}
|
}
|
||||||
fclose(f);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace ue2
|
} // namespace ue2
|
||||||
|
Loading…
x
Reference in New Issue
Block a user