What happened to that suspicious-looking guy hanging around the entrance?
One of the fun parts of attending a conference is swapping stories with other professionals. Today's story is in honor of Global Security Week. (And retroactively in honor of the upcoming //build...
View ArticleWhy is the registry a hierarchical database instead of a relational one?
Commenter ton asks why the registry was defined as a hierarchical database instead of a relational database. Heck, it's not even a hierarchical database! The original registry was just a dictionary;...
View ArticleWhy doesn't the Disk Management snap-in incorporate S.M.A.R.T. data?
My article a while back on Why the Disk Management snap-in reports my volume as Healthy when the drive is dying gave the low-level explanation of why the Disk Management snap-in does not incorporate...
View ArticleWhy waste your money on the car when it's the sound system you care about?
There is apparently a subculture of people who decide to economize on the car part of the "loud stereo in car" formula (since they really don't care about the car—it's all about the music) and put...
View ArticleThrowing garbage on the sidewalk: The sad history of the rundll32 program
During the development of Windows Vista, the application comaptibility team traced a bunch of issues back to people corrupting the stack by using the rundll32 program to call functions that were not...
View ArticleIs this a really bug with CreateWindowEx or am I just confused?
Somebody sent me email pointing out strange behavior in the MessageBox function if you fail a window creation by returning −1 from the WM_CREATE message. On the other hand, returning FALSE from...
View ArticleWhy are the building numbers on Microsoft main campus so erratic?
Carrie complains that the building numbers on Microsoft main campus are completely random. Why is building 22 near buildings 40 and 41, far, far away from building 24? Because the Microsoft campus...
View ArticleA common control for associating extensions is well overdue
Mark complained that a common control for associating extensions is *well* overdue. This is a recurring theme I see in the comments: People complaining that Windows lacks some critical feature that it...
View ArticleWhat happens to a sent message when SendMessageTimeout reaches its timeout?
The SendMessageTimeout function tries to send a message, but gives up if the timeout elapses. What exactly happens when the timeout elapses? It depends. The first case is if the receiving thread...
View ArticleSome preliminary notes from //build/ 2011
Hey everybody, I'm down at the //build/ conference. (The extra slash is to keep the d from falling over.) I'm not speaking this year, but you can find me in the Apps area of the Expo room today until...
View ArticleWhy can't I PostMessage the WM_COPYDATA message, but I can SendMessageTimeout...
After receiving the explanation of what happens to a sent message when SendMessageTimeout reaches its timeout, a customer found that the explanation raised another question: If the window manager...
View ArticleThe clipboard viewer linked list is no longer the responsibility of...
Commenter Nice Clipboard Manager (with drop->clipboard) wonders why Windows still uses a linked list to inform programs about clipboard modifications. If any clipboard viewer fails to maintain the...
View ArticleMicrospeak: The bug farm
In its most general sense, the term bug farm refers to something that is a rich source of bugs. It is typically applied to code which is nearly unmaintainable. Code can arrive in this state through a...
View ArticleRandom notes from //build/ 2011
Here are some random notes from //build/ 2011, information of no consequence whatesoever. A game we played while walking to and from the convention center was spot the geek. "Hey, there's a guy...
View ArticleWhy do Windows functions all begin with a pointless MOV EDI, EDI instruction?
If you look at the disassembly of functions inside Windows DLLs, you'll find that they begin with the seemingly pointless instruction MOV EDI, EDI. This instruction copies a register to itself and...
View ArticleWhy does my single-byte write take forever?
A customer found that a single-byte write was taking several seconds, even though the write was to a file on the local hard drive that was fully spun-up. Here's the pseudocode: // Create a new file -...
View ArticleWhy does my asynchronous I/O complete synchronously?
A customer was creating a large file and found that, even though the file was opened with FILE_FLAG_OVERLAPPED and the WriteFile call was being made with an OVERLAPPED structure, the I/O was...
View ArticleSending a window a WM_DESTROY message is like prank calling somebody...
A customer was trying to track down a memory leak in their program. Their leak tracking tool produced the stacks which allocated memory that was never freed, and they all seemed to come from...
View ArticleAh, the exciting world of cross-forest dogfood
The Windows group has its own domain (known as NTDEV for historical reasons) which operates separately from the domain forest operated by the Microsoft IT department. Various trust relationships need...
View ArticleDoes this operation work when impersonating? The default answer is NO
I'll often see a customer ask for assistance with a scenario like this: "We're having trouble doing X. We're doing X1, X2, and X3, but it looks like we're getting the wrong answer back." The next step...
View Article