Skip to content

Commit

Permalink
core, bugfix: runtime error in i386 mode on Windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
xicilion committed Apr 24, 2021
1 parent f438eef commit 52ba9f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fibjs/src/base/string.cpp
Expand Up @@ -22,7 +22,7 @@ class ExtStringW : public v8::String::ExternalStringResource {

~ExtStringW()
{
m_isolate->AdjustAmountOfExternalAllocatedMemory(-m_buffer.length() * 2);
m_isolate->AdjustAmountOfExternalAllocatedMemory(-(int64_t)m_buffer.length() * 2);
}

public:
Expand Down Expand Up @@ -57,7 +57,7 @@ class ExtString : public v8::String::ExternalOneByteStringResource {

~ExtString()
{
m_isolate->AdjustAmountOfExternalAllocatedMemory(-m_buffer.length());
m_isolate->AdjustAmountOfExternalAllocatedMemory(-(int64_t)m_buffer.length());
}

public:
Expand Down

0 comments on commit 52ba9f8

Please sign in to comment.