From 2b994d9e3770fb5da9b062f287e0dff03e0b5a45 Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Tue, 6 Oct 2009 10:45:18 +0200 Subject: [PATCH] Also accept 'utf-8' to specify utf8 encodings. --- src/node.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/node.cc b/src/node.cc index f452f66028..8ccbcd5c33 100644 --- a/src/node.cc +++ b/src/node.cc @@ -39,6 +39,8 @@ enum encoding ParseEncoding(Handle encoding_v, enum encoding _default) { if (strcasecmp(*encoding, "utf8") == 0) { return UTF8; + } else if (strcasecmp(*encoding, "utf-8") == 0) { + return UTF8; } else if (strcasecmp(*encoding, "ascii") == 0) { return ASCII; } else if (strcasecmp(*encoding, "binary") == 0) {