Quantcast
Channel: The Old New Thing
Browsing all 3085 articles
Browse latest View live

Predator-prey reversal: Rock lobsters vs whelks on Malgas Island and Marcus...

Malgas Island is dominated by rock lobsters, who happily feast upon whelks. Just 4km away, Marcus Island is dominated by whelks, not a rock lobster to be found. Researcher Amos Barkai couldn't figure...

View Article


How do I destruct an object that keeps a reference to itself, because that...

Consider the case of an ordered work queue. Components can queue work to the worker thread, with the expectation that the work will run sequentially. class OrderedWorkQueue { public:...

View Article


What order are pages in a memory-mapped file flushed out to disk?

Say you create a memory-mapped file mapping and write data to it. In which order will the pages be flushed out to disk? Is it in the order the pages were written? Or are pages closer to the beginning...

View Article

Even if your assembly language code doesn’t call any Windows APIs, you still...

Writing in assembly language doesn't absolve you from adhering to the software conventions. Certainly you have more flexibility in assembly language, but that doesn't give you freedom to do anything...

View Article

Precision questioning: The cynical description

Precision questioning is a technique used by some senior executives at Microsoft. Although precision questioning positions itself as a toolkit for critical thinking and problem solving, its use in...

View Article


Asking for clear written documentation that Require trusted path for...

A customer had turned on the Require trusted path for credential entry policy (under Computer Configuration, Administrative Templates, Windows Components, Credential User Interface). They demanded...

View Article

Image may be NSFW.
Clik here to view.

Why is there a limit of 15 shell icon overlays?

There is a limit of fifteen shell icon overlays. Why fifteen? The value 15 came from the corresponding limit for image lists. The Image­List_Set­Overlay­Image function supports up to 15 image list...

View Article

What does the N in nmake stand for?

The Visual Studio toolchain comes with a tool called nmake. It processes files in roughly the same way as the traditional Unix make tool. Why is it called nmake instead of just make? Rewind back to the...

View Article


When do Core­Dispatcher.Run­Async and Thread­Pool.Run­Async actions complete?

The Core­Dispatcher::Run­Async and Thread­Pool::Run­Async methods take a delegate and schedule it to be invoked on the dispatcher thread or on a thread pool thread. These methods return an...

View Article


How do I wait for the completion of the delegate I passed to...

As we saw last time, The the Core­Dispatcher::Run­Async and Thread­Pool::Run­Async methods complete when the delegate returns, which is not the same as when the delegate completes. How can you wait...

View Article

C++/WinRT envy: Bringing thread switching tasks to C# (UWP edition)

Last time, we developed a Run­Task­Async method to try to make it easier to switch threads in a task, but we saw that while it simplified some operations, it was still cumbersome because of the...

View Article

C++/WinRT envy: Bringing thread switching tasks to C# (WPF and WinForms edition)

Last time, we brought Thread­Switcher.Resume­Foreground­Async and Thread­Switcher.Resume­Background­Async to C# for UWP. Today, we’ll do the same for WPF and Windows Forms. It’ll be easier the second...

View Article

Oh no, it’s inspection time again

I recreate below a memo attached to the office doors of some occupants of the Microsoft RedWest campus fourteen years ago today. From: Reel Estate & Faculties Executive NotificationsSent: Friday,...

View Article


On the bogosity of speculation: Guessing the price of the original Surface

It appears that Windows 8 followed the teaser model: Show people a glimpse of the future, and then don’t mention it again until you have another big announcement. It happened in June 2011, when a brief...

View Article

Dubious security vulnerability: Code execution via LNK file

A security vulnerability report arrived that claimed to have achieved code execution via a shortcut (LNK) file. The report was somewhat convoluted, but it went something like this: Start with this...

View Article


Why do we need atomic operations on the 80386, if it doesn’t support...

The 80386 processor did not support symmetric multiprocessing, yet we discussed atomic operations when in our overview of the processor. If the processor doesn’t even support symmetric multiprocessing,...

View Article

What does it mean when my attempt to stop a Windows NT service fails with...

A customer reported that they had a sporadic problem: Their product includes a Windows NT service, and when their client program tries to stop the service, it sometimes fails with ERROR_BROKEN_PIPE....

View Article


Optimizing your cafeteria meal card stockpile

As I noted when I told the story of getting one’s paycheck from some mysterious pile of money, I had a colleague with a lot of money-related quirks. Back in the early 1990’s, payment for food in the...

View Article

How to compare two packed bitfields without having to unpack each field

Suppose you are packing multiple bitfields into a single integer. Let's say you have a 16-bit integer that you have packed three bitfields into: 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 r g b Suppose you...

View Article

My initial frustration trying to configure our internal VoIP phones that were...

I remember when Microsoft made their initial internal roll-out of its VoIP phones. The VoIP phones were integrated with a desktop app which let you configure the phone, managed your telepresence, as...

View Article
Browsing all 3085 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>