Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

small misc change in src folder 19-03-20 #26815

Closed
wants to merge 6 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/base_object.h
Original file line number Diff line number Diff line change
@@ -40,6 +40,8 @@ class BaseObject : public MemoryRetainer {
inline BaseObject(Environment* env, v8::Local<v8::Object> object);
inline ~BaseObject() override;

BaseObject() = delete;

// Returns the wrapped object. Returns an empty handle when
// persistent.IsEmpty() is true.
inline v8::Local<v8::Object> object() const;
@@ -74,8 +76,6 @@ class BaseObject : public MemoryRetainer {
Environment* env);

private:
BaseObject();

v8::Local<v8::Object> WrappedObject() const override;
bool IsRootNode() const override;
static void DeleteMe(void* data);
7 changes: 1 addition & 6 deletions src/cares_wrap.cc
Original file line number Diff line number Diff line change
@@ -296,18 +296,13 @@ void node_ares_task::MemoryInfo(MemoryTracker* tracker) const {
node_ares_task* ares_task_create(ChannelWrap* channel, ares_socket_t sock) {
auto task = new node_ares_task();

if (task == nullptr) {
/* Out of memory. */
return nullptr;
}

task->channel = channel;
task->sock = sock;

if (uv_poll_init_socket(channel->env()->event_loop(),
&task->poll_watcher, sock) < 0) {
/* This should never happen. */
free(task);
delete task;
return nullptr;
}

1 change: 0 additions & 1 deletion src/env.cc
Original file line number Diff line number Diff line change
@@ -8,7 +8,6 @@
#include "node_internals.h"
#include "node_native_module.h"
#include "node_options-inl.h"
#include "node_platform.h"
#include "node_process.h"
#include "node_v8_platform-inl.h"
#include "node_worker.h"
2 changes: 0 additions & 2 deletions src/heap_utils.cc
Original file line number Diff line number Diff line change
@@ -280,15 +280,13 @@ class HeapSnapshotStream : public AsyncWrap,

int DoShutdown(ShutdownWrap* req_wrap) override {
UNREACHABLE();
return 0;
}

int DoWrite(WriteWrap* w,
uv_buf_t* bufs,
size_t count,
uv_stream_t* send_handle) override {
UNREACHABLE();
return 0;
}

bool IsAlive() override { return snapshot_ != nullptr; }
1 change: 0 additions & 1 deletion src/module_wrap.h
Original file line number Diff line number Diff line change
@@ -36,7 +36,6 @@ v8::Maybe<url::URL> Resolve(Environment* env,

class ModuleWrap : public BaseObject {
public:
static const std::string EXTENSIONS[];
static void Initialize(v8::Local<v8::Object> target,
v8::Local<v8::Value> unused,
v8::Local<v8::Context> context,