Skip to content

Commit 6cc7e2a

Browse files
committed
Never cache SID_ALLOCATION.txt
Adds a flag to the windows internet call to ignore caches
1 parent 2effa3b commit 6cc7e2a

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

BeluxPlugin/BeluxPlugin.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919

2020
#define MY_PLUGIN_NAME "Belux"
21-
#define MY_PLUGIN_VERSION "1.3.2"
21+
#define MY_PLUGIN_VERSION "1.3.4"
2222
#define MY_PLUGIN_DEVELOPER "Nicola Macoir, Stef Pletinck for Belux vACC"
2323
#define MY_PLUGIN_COPYRIGHT "GPL v3"
2424
#define MY_PLUGIN_VIEW_AVISO "Belux vACC"

BeluxPlugin/BeluxUtil.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ string BeluxUtil::https_fetch_file(string url)
8585
// TODO handle null internet_handle
8686
HINTERNET internet_handle = InternetOpen("Belux Plugin", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0);
8787
// TODO handle null handle
88-
HINTERNET url_handle = InternetOpenUrl(internet_handle, url.c_str(), NULL, 0, 0, NULL);
88+
HINTERNET url_handle = InternetOpenUrl(internet_handle, url.c_str(), NULL, 0, INTERNET_FLAG_RELOAD, NULL);
8989
// TODO download shit
9090
constexpr size_t buffer_block_size = 5120; // 5kiB, should be enough in most cases as a start
9191
size_t buffer_size = buffer_block_size;

BeluxPlugin/ProcedureAssigner.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,8 +174,7 @@ std::optional<SidEntry> ProcedureAssigner::process_flight_plan(const EuroScopePl
174174
size_t ProcedureAssigner::fetch_sid_allocation() const
175175
{
176176
const std::string url = "https://beluxvacc.org/files/navigation_department/datafiles/SID_ALLOCATION.txt";
177-
const std::string allocation = BeluxUtil::https_fetch_file(
178-
"https://beluxvacc.org/files/navigation_department/datafiles/SID_ALLOCATION.txt");
177+
const std::string allocation = BeluxUtil::https_fetch_file(url);
179178
return sid_allocation.parse_string(allocation);
180179
}
181180

0 commit comments

Comments
 (0)