Geeks With Blogs
Zackary Geers blog March 2007 Entries
Ascii Encoding isn't what I thought it was.
I spent the past few hours hunting down a hidden bug in our code. ASCIIEncoding isn't what you think it is offhand, it only deals with the lower 7 bits. System.Text.Encoding.AsciiE... doesn't support characters with accents. I'm switching from using AsciiEncoding to using Encoding.GetEncoding(1252). Codepage-1252 is what I always think of when I think about Ascii encoding, even though it's not actually Ascii ......

Posted On Wednesday, March 28, 2007 1:28 AM

BLAH! I've found out there's an issue with HttpWebRequest in 1.1 where it will mysteriously stop downloading files (may be related to https), yet when I switch to 2.0, my code works perfectly. While I'm glad I've found a way to get it working, it drive me nuts! Also I hear rumors that there may be a bug with HttpWebRequest not properly flushing when you call GetResponse, though I haven't figured that one out yet. I'm tired but I have working code, understanding the bug is something I will have to ......

Posted On Friday, March 23, 2007 7:54 AM

Copyright © Zackary Geers | Powered by: