Showing archive results for 2008

Jun 13, 2008
Post comments count0
Post likes count1

Don't be helpless: You can find information, too, if you try

Raymond Chen

Here's a question that floated past my view: Anybody know if there exists a library for computing MD5 hashes from unmanaged code? MSDN has information about .NET classes, but nothing about the unmanaged side. Hm, let's see. Wow, those hits sure look promising. Perhaps a search on Windows Live or Google¹ will turn up something. Oh hey...

Other
Jun 12, 2008
Post comments count0
Post likes count1

Email tip: Pronouns in the subject line are in the eye of the beholder

Raymond Chen

This applies to email, but it applies even more to meetings and appointments, which are typically arranged via email or similar workflow. It may seem obvious at the time, but messages with pronouns like me or you in the subject line tend to be harder to understand when you come back to the message a little while later. I was reminded of this by a...

Non-Computeremail
Jun 11, 2008
Post comments count0
Post likes count1

If you say that you don't care about something, you shouldn't be upset that it contains garbage

Raymond Chen

There are many situations where you pass a structure to a function, and the function fills in the structure with information you request. In some cases, the function always fills in the entire structure (example: ). In other cases, you tell the function which bits of information you care about, to save the function the effort of computing somethin...

Code
Jun 10, 2008
Post comments count0
Post likes count0

Simply attach a piano to the end of the trebuchet

Raymond Chen

As easy as 1-2-3. What's really scary is that they are hardly the only people to have done this. An Internet search will reveal many other people who've expressed similar musical talent. Or you can build one out of an industrial robot and hurl flaming bowling balls.

Non-Computer
Jun 10, 2008
Post comments count0
Post likes count1

There are only twelve function keys, and who says there's somebody there to push them?

Raymond Chen

One of the proposals for adding hidden features to Windows Setup is to have a bunch of hidden function keys, one for each hidden option. Well, first of all, there are only twelve function keys and there are way more than twelve possible Setup features. (Yes, there may be a few function keys still active during Setup, but they exist only for compat...

Other
Jun 9, 2008
Post comments count0
Post likes count0

Money: The new plagiarism

Raymond Chen

It appears that the country of Burundi used a freelance photographer's image on their currency without permission. (If the article goes down, BoingBoing saved a side-by-side comparison for your inspection.) The article adds that Fajack says he's talked about his case with several lawyers, editors and people experienced in photography and none of...

Non-Computer
Jun 9, 2008
Post comments count0
Post likes count1

Why are DLLs uninitialized in the "wrong" order?

Raymond Chen

This is really just a corollary to Why are DLLs unloaded in the "wrong" order. Exactly the same logic that explains why DLLs are unloaded in the "wrong" order also explains why they are uninitialized in the "wrong" order. Once you understand the first issue, the second comes for free; just change to in your analysis. Apply the logic to the sc...

Code
Jun 6, 2008
Post comments count0
Post likes count0

Million Dollar Password: At least it shares a name with the original

Raymond Chen

Password was one of the classic game shows. Its methodical pace encouraged thoughtful play, as opposed to today's game shows which appear to rely on dramatic music and ominous spotlights for their appeal. This is not a clip from the game show but rather a scene from the comedy The Odd Couple in which the two characters are contestants, and as you...

Non-Computer
Jun 6, 2008
Post comments count0
Post likes count1

Why does OpenProcess succeed even when I add three to the process ID?

Raymond Chen

A customer noticed that if you add three to a process ID and pass it to the function, it still succeeds. Why is that? Well, first of all, I need to say up front that the behavior you're seeing is an artifact of the implementation and is not part of the contract. You're passing intentionally invalid parameters, what did you expect? The context of...

Code
Jun 5, 2008
Post comments count0
Post likes count0

Portugal TechDays 2008: A report

Raymond Chen

Back in March, I agreed to make a brief appearance at Portugal TechDays 2008. My arrival was delayed due to heavy traffic: I had taken the number 15 tram, which was jam packed, and the traffic on the road didn't help either. And then when I found the building labelled Centro de Congressos, I found the doors locked. That's because the big sign fac...

Other