diff --git a/src/node_buffer.cc b/src/node_buffer.cc index d304063abc7..f9317c479dd 100644 --- a/src/node_buffer.cc +++ b/src/node_buffer.cc @@ -91,7 +91,9 @@ bool HasInstance(Handle obj) { char* Data(Handle val) { assert(val->IsObject()); - return Data(val.As()); + // Use a fully qualified name here to work around a bug in gcc 4.2. + // It mistakes an unadorned call to Data() for the v8::String::Data type. + return node::Buffer::Data(val.As()); }