richardc-db commented on a change in pull request #34086:
URL: https://github.com/apache/spark/pull/34086#discussion_r716894990



##########
File path: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/hash.scala
##########
@@ -111,8 +112,10 @@ case class Sha2(left: Expression, right: Expression)
         // DigestUtils doesn't support SHA-224 now
         try {
           val md = MessageDigest.getInstance("SHA-224")
-          md.update(input)
-          UTF8String.fromBytes(md.digest())
+          val messageDigest = md.digest(input);

Review comment:
       Yep, thanks for catching that! I switched it over to use `DigestUtils` 
and it seems to work.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to