Skip to content

Commit

Permalink
Fixed offset that out of bounds
Browse files Browse the repository at this point in the history
  • Loading branch information
grodansparadis committed Jan 30, 2025
1 parent 4a845e1 commit 20b1115
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions src/vscp/common/mdf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1746,8 +1746,7 @@ CMDF::downLoadMDF(const std::string &url, const std::string &tempFileName)
CURL *curl;
FILE *fp;
CURLcode res;
// char *url = "http://localhost/aaa.txt";
// char outfilename[FILENAME_MAX] = "C:\\bbb.txt";

curl = curl_easy_init();
if (curl) {
fp = fopen(tempFileName.c_str(), "wb");
Expand Down
2 changes: 1 addition & 1 deletion src/vscp/common/register.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1349,7 +1349,7 @@ CStandardRegisters::getFirmwareVersionString(void)
{
std::string str;

str = str = vscp_str_format("%d.%d.%d", m_regs[0x94 - 0x80], m_regs[0x95 - 0x80], m_regs[0x96 - 0x80]);
str = str = vscp_str_format("%d.%d.%d", m_regs[0x94], m_regs[0x95], m_regs[0x96]);
return str;
}

Expand Down

0 comments on commit 20b1115

Please sign in to comment.