Posts by this author

Dec 6, 2006
Post comments count0
Post likes count0

The wisdom of seventh graders: What to do with a time machine (part 3)

(Continuing from part 2.) Here are more sentences from seventh grade time travel essays. Remember, these sentences are not representative of seventh grade writing in general; these are just the funny bits. World History The Future: Most students who travelled to the future wanted to meet themselves. Letter Format: Some students took advan...

Non-ComputerThe wisdom of seventh graders
Dec 6, 2006
Post comments count0
Post likes count2

If you let people read a file, then they can copy it

Here's a question that floated past my view: How do I set the ACLs on a file so users can read it but can't copy it? I can't find a "Copy" access mask that I can deny. If I can't deny copying, I'd at least like to audit it, so I can tell who made a copy of the file. There is no "Copy" access mask because copying is not a fundamental file operati...

Other
Dec 5, 2006
Post comments count0
Post likes count0

The wisdom of seventh graders: What to do with a time machine (part 2)

(Make sure you've read Part 1 for background information.) On the subject of where they would go in a time machine, many students wrote well-thought-out essays, beautifully composed. These sentences below did not come from those essays. I've categorized the snippets roughly by theme, though I had to guess at some of them since the sentences are...

Non-ComputerThe wisdom of seventh graders
Dec 5, 2006
Post comments count0
Post likes count0

How do I find all files with at least one space in their name?

You already know how to do this, you just don't realize it. How do you find files with an "x" in their name? That's right, you use . Now you just have to change that x to a space. And since spaces are command line delimiters, you need to quote the sequence so it gets treated as a single parameter rather than two "*" parameters: Stick in a ...

Tips/Support
Dec 4, 2006
Post comments count0
Post likes count0

The wisdom of seventh graders: What to do with a time machine (part 1)

All the students at a local school were asked to composed an in-class essay on the following topic: "Your science teacher has invented a time machine. You have been selected to take the first trip. Explain in a multi-paragraph letter to your teacher where you will go and why." (Students were given two hours, plus one additional hour upon request. I...

Non-ComputerThe wisdom of seventh graders
Dec 4, 2006
Post comments count0
Post likes count0

The name WinMain is just a convention

Although the function is documented in the Platform SDK, it's not really part of the platform. Rather, is the conventional name for the user-provided entry point to a Windows program. The real entry point is in the C runtime library, which initializes the runtime, runs global constructors, and then calls your function (or if you prefer a...

Code
Dec 1, 2006
Post comments count0
Post likes count0

Nailing down what constitutes valuable consideration

Last time, I introduced a friend I called "Bob" for the purposes of this story. At a party earlier this year, I learned second-hand what Bob had been up to more recently. The team Bob worked for immediately prior to his retirement gave him a call. "Hi, Bob. We're trying to ship version N+1 of Product X, and we really need your help. I k...

Other
Nov 30, 2006
Post comments count0
Post likes count0

It took two of us to keep up with one Bob

One of my friends (let's call him "Bob") retired from Microsoft many years ago. Bob is an amazing programmer whose skills I remain in awe of. I remember visiting his office one evening with a mutual friend ("Fred") to catch up on things. When we turned up, he showed us a problem that he was working on. He was doing some sort of fancy graphics effe...

Other
Nov 29, 2006
Post comments count0
Post likes count0

A fork is an easy-to-find nonstandard USB device

Remember the Ten Immutable Laws of Security. Today, we're going to talk about number three: If a bad guy has unrestricted physical access to your computer, it's not your computer any more. There was a bug which floated past my field of vision many months ago that went something like this: "I found a critical security bug in the USB stack. If some...

Other
Nov 28, 2006
Post comments count0
Post likes count0

What went wrong in Windows 95 if you use a system color brush as your background brush?

If you want to register a window class and use a system color as its background color, you set the member to the desired color, plus one, cast to an : Windows 95 introduced "system color brushes", which are a magic type of brush which always paint in the corresponding system color, even if the system color changes. The brush will alwa...

CodeHistory