Skip to main content

Posts

Windows 7: How To Ignore Reports of Danger

I am running Windows 7 via VirtualBox, and I skipped Vista completely, so some of my comments might also apply to Vista and thus be outdated. Too bad. You can probably expect a few other short pieces as I find something I like and something I don't. So, we see Internet Explorer here trying to help you out and tell you the download seems safe. Of course, it also lets you report that the download is, in fact, unsafe! This will no doubt be fed back into their SmartScreen Filter service, and when enough users report something, future users will be warned on downloading whatever bit of malware it might be. What a great way to protect your users. Now, the only obvious place to report the download is right here, in the download dialog box, which disappears as soon as the download completes and you can open or run it and actually discover anything threatening about it to warn others about. My Windows 7 review will eventually be the composite of many small pieces. I'll build up a score ...

How To Win By Not Mattering

This is all about the strange and confusing state of win we see repeatedly today, where a brand or concept gains such control and mindshare that no one even recognizes them as a thing anymore. Few people think of Q-tips as a brand versus just being the name of a thing. Pepsi Co executives probably grind their teeth thinking about movie goers ordering "just a coke" when Pepsi products are prominently and solely for sale. Most Internet Explorer users go beyond not understanding what IE is, they don't even understand what a browser is! Today, I want to talk about something newer and more specific, and less sure. The direction is visible that Mercurial is being given steps (it is important to phrase it this way, as I'll explain) to not matter, and that is precisely why they will win. CVS still matters, which is precisely why it has lost so utterly in the imaginary battle for geek mindshare. If you are using CVS, it is important to remember that along the way, because it a...

How To Install Google Gears on 64-bit Linux

This is just a quicky tutorial for anyone else hitting the problem I had: installing Google Gears on 64-bit Linux. Google has not released support for this officially, but are apparently working on it and while there have been no official beta releases to try it out, someone posted a 64-bit build on a forum post . This will give you an XPI, the packaging format used by Firefox extensions, but it won't work right away. Firefox needs some special instructions to make a link actually install something and the forum post doesn't include it. There are no obvious ways to tell Firefox, "Install this XPI at this URI," so what are we to do? It turns out that it will initiate an installation if you select the XPI from the "Open File..." option in the File menu. So, download it locally and then open it in this manner, and you'll restart Firefox with a working Google Gears extension. Enjoy. I've got to get back to work now. So little time to post these days!

How To Prove Code Review is Important

The infamous Zune 30GB failures were traced to a leapyear issue, and apparently they use some code we can see in the Freescale codebase. Take a look at the following sample of code, which determines the year from the day number (counting from January 1, 1980). I don't know about you, but the infinite loop is immediately obvious.  On a leapyear, the main loop continues when days = 366  and the incrementing is never reached, because days > 366  fails. Am I naive to think that even a casual code review would have caught this in a moment? year = ORIGINYEAR; /* = 1980 */ while (days > 365) { if (IsLeapYear(year)) { if (days > 366) { days -= 366; year += 1; } } else { days -= 365; year += 1; } } UPDATE: Fixed formatting issues. It looked fine when I posted it, honest!

How To Measure The Merb/Rails Merge

This is a two part posting, hopefully. The first part is a request from me to my Rails-using readers. (Do I have Rails-using readers?) Can you leave lots of comments telling a non-Ruby guy like me what importance the Rails/Merb merger I've been hearing about means for the wider web developer community?

How To Be Dissappointed in Something You Recommend

I recommend purchasing Expert Python Programming, by Tarek Ziadé . I am extremely disappointed in this book, but I'm recommending it specifically if you already have a good grasp of Python. You see, I was really looking forward to recommending this book. I had hoped that the many people I know with a good developer head on their shoulders, but had not approached Python with seriousness before, would find this a perfect introduction to sit down with. While I'm really pleased with the writing and structure of the content, I'm afraid this is a book suffering from severe editing oversights. There are subtle mix-ups in terminology in many places and some code samples that are simply and absolutely incorrect. This is where I made my decision: >>> from threading import RLock >>> lock = RLock() >>> def synchronized(function): ...     def _synchronized(*args, **kwargs): ...         lock.acquire() ...         try: ...             return function(*args, **kw...