Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×

Comment Mishandling handles (Score 1) 285

I once contracted with a shop that had a process that generated garbled output data rows. It appeared to be extra stuff that didn't affect (over-write) the intended rows. The shop had added an extra processing step to filter out the garbage rows and eventually just worked around the glitch.

They had asked me to try to track it down, among other projects, because they were newbie programmers. I couldn't figure it out either because it never appeared in my intermediate trace statements. I put a trace (print) statement before every "write" in the program. None of the prints showed the garbage, yet garbage ended up in the output file. Head-scratcher galore. I was supposed to be "the expert", and thus feeling a bit deflated.

On I think the last day of my contract, I was running a test copy of the code with some changes to perform speed tests. I went to try a certain speed tweak, and I suddenly spotted the error: the file handle variable was re-used for another non-handle purpose, something like this:

fhandle = openFileForWrite(fileName);
...
writeToFile(fhandle, someData);
...
fhandle = countX + countY - 7;
...
closeFile(fhandle);

The actual handle name was something like "qhand". But a regular variable, "quantity on hand" ended up "qhand" also, the same name as the file handle.

When it dawned on me what happened, I started screaming like a wildman and the others popped out of their cubicles to see what was going down. They took my coffee away :-)

As far as the link on goofy video game bugs, I remember somebody discovered that if you don't put a game cartridge in all the way, certain characters dance and spin randomly and rapidly in the sky.

It created an Internet meme, and spoofs started appearing all over, typically using stop-motion with live actors. I forgot the nickname of the meme, but I found it hilarious. It took my mind off the handle bug.

Comment Hindsight and lessons. (Score 1) 279

I don't blame Google for trying. There are too many variables to say what will work and won't. Social networking is too big of an industry to not bother making a play for. Honda started out a successful motorbike company, and successfully pushed into automobiles even though that industry was full of established players.

However, I do blame Google for forcing their services to be or act like a social networking site, where private info magically showed up elsewhere in unexpected ways. That's just desperation and/or forceful denial in play, ticking off your user base. They forgot "Don't Be Evil". Obsession made them stupid.

I hope Google goes back to what it does well: lots of specialized little services that can OPTIONALLY share info between each other as the user sees fit.

Comment Tales of Customs (Score 1) 75

cut the cables between the two boards [of a TRS-80] and send them separately to avoid getting caught in customs.

Reminds me of the story of Richard Garriott's Sputnik 1. It's an actual spare probe prepared by the Soviets in the 1950's as a backup.

When Russia was having a hard time transitioning away from Soviet rule in the 90's, Soviet space stuff was being auctioned for ridiculously low prices.

Richard snapped up the spare Sputnik for a bargain, and disassembled it to get it past customs. His team unscrewed the metal sphere into two halves and presented them as "new-age salad bowls" to customs officials.

http://www.nytimes.com/2007/10...

Comment Victory for "Soft" Socialism (Score 1) 904

Subsidizing the cost of nascent "green" technology is needed to prod the industry to produce and learn how to make a better green mouse-trap through experience and R&D.

It's paying off now as electric cars are getting competitive. Gasoline engines have been the dominant car technology for a century, and thus have had a lot of R&D behind them. Thanks to subsidies to induce sales and R&D, electric cars have evolved to be competitive with gasoline.

Private companies rarely look more than 5 to 10 years ahead. It's why they have to be prodded via subsidies, etc. Finance theory on ROI teaches one to generally focus on the short-term. Whether this is entirely rational or not makes an interesting debate, but it's the ruling view of the current business world.

By the way, I consider "soft" socialism to be incentive-based. "Hard" socialism would be outright banning products. I'm generally against outright banning for products, such as incandescent bulbs and sugar-loaded Big Gulps. Tax them heavily as a disincentive, but don't ban them.

Slashdot Top Deals

A morsel of genuine history is a thing so rare as to be always valuable. -- Thomas Jefferson

Working...