Skip to content
Closed
Changes from 1 commit
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
Prev Previous commit
Next Next commit
style
  • Loading branch information
zhichao-li committed Jun 30, 2015
commit 11945c768b9b7de9b44e5cafeef66f0e8f702f52
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@ case class UnHex(child: Expression)
unhex(num.asInstanceOf[UTF8String].toString)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Converting UTF8String to String is slow, please use getBytes

}
}

private def unhex(s: String): Array[Byte] = {
// append a leading 0 if needed
val str = if (s.length % 2 == 1) {"0" + s} else {s}
Expand Down