Skip to content
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.

Commit

Permalink
build: fix build break
Browse files Browse the repository at this point in the history
  • Loading branch information
boingoing committed Jan 17, 2018
1 parent e104f74 commit 0f6eee1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions deps/chakrashim/include/v8-platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
#include <stdint.h>
#include <string>
#include <memory>
#include <chrono>

namespace v8 {

Expand Down Expand Up @@ -145,6 +146,7 @@ class Platform {
}

virtual double MonotonicallyIncreasingTime() = 0;
virtual double CurrentClockTimeMillis() = 0;
typedef void(*StackTracePrinter)();

virtual StackTracePrinter GetStackTracePrinter() { return nullptr; }
Expand Down Expand Up @@ -187,6 +189,12 @@ class Platform {
typedef v8::TracingController::TraceStateObserver TraceStateObserver;
virtual void AddTraceStateObserver(TraceStateObserver*) {}
virtual void RemoveTraceStateObserver(TraceStateObserver*) {}

protected:
static double SystemClockTimeMillis() {
return std::chrono::duration_cast<std::chrono::milliseconds>(
std::chrono::system_clock::now().time_since_epoch()).count();
}
};

} // namespace v8
Expand Down
2 changes: 1 addition & 1 deletion src/node_buffer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,7 @@ void Fill(const FunctionCallbackInfo<Value>& args) {
// string is invalid. This will trigger a throw in JavaScript. Silently
// failing should be avoided because it can lead to buffers with unexpected
// contents.
if (str_length == 0)
if (str_length == 0) {
#if ENABLE_TTD_NODE
TTD_NATIVE_BUFFER_ACCESS_NOTIFY("Fill Questionable Case");
#endif
Expand Down

0 comments on commit 0f6eee1

Please sign in to comment.