Skip to content

Commit

Permalink
BsonSymbol had a similar utf8 length problem
Browse files Browse the repository at this point in the history
  • Loading branch information
srp committed Apr 16, 2010
1 parent cb22311 commit 7882383
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Database/MongoDB/BSON.hs
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ putVal (BsonRegex r opt)= do putS r
putByteString $ pack $ List.sort opt
putNull
putVal (BsonJSCode c) = putStrSz c
putVal (BsonSymbol s) = putI32 (fromIntegral $ 1 + L8.length s) >> putS s
putVal (BsonSymbol s) = putStrSz s
putVal (BsonJSCodeWScope q s) =
let bytes = runPut (putStrSz q >> putObj s)
in putI32 ((+4) $ fromIntegral $ L.length bytes) >> putLazyByteString bytes
Expand Down

0 comments on commit 7882383

Please sign in to comment.