Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
Bug

Pet Bugs? 1261

benreece asks: "During my few years as a programmer/developer I've come across some strange bugs. Recently I found that Microsoft's VB/VBScript(ASP) round function has problems (for example, 'round(82.845)' returns '82.84' instead of '82.85'). It took me an annoyingly long time to realize the problem wasn't mine. I'm wondering what other obscure, weird, and especially annoying bugs in languages/compilers/etc have frustrated other developers." Memorable bugs. Every developer has one. What were yours?
This discussion has been archived. No new comments can be posted.

Pet Bugs?

Comments Filter:
  • worst bug (Score:-1, Funny)

    by kitts ( 545683 ) on Wednesday June 26, 2002 @03:54PM (#3771689) Homepage
    windows...
  • by Cleon ( 471197 ) <cleon42.yahoo@com> on Wednesday June 26, 2002 @03:55PM (#3771697) Homepage
    MS Visual Studio. The whole thing.

    The compiler is weird, the debugging is painful, and the linker is just plain wonky.
  • by tenman ( 247215 ) <slashdot.org@netsuai. c o m> on Wednesday June 26, 2002 @03:56PM (#3771698) Journal
    Here is the first ever computer bug... [vt.edu]


    back with more in a minute
  • Ah, so! (Score:2, Funny)

    by eyepeepackets ( 33477 ) on Wednesday June 26, 2002 @03:57PM (#3771704)
    No wonder my banker is always smiling when he sees me -- he's using VB script!

  • by kwishot ( 453761 ) on Wednesday June 26, 2002 @03:57PM (#3771706)
    All those times when slashdot is messed up and you click on a comment only to be brought back to the front page...
  • True story (Score:3, Funny)

    by WinDoze ( 52234 ) on Wednesday June 26, 2002 @03:57PM (#3771708)
    I discovered that Visual Basic has a bug where it turns otherwise comptent programmers into drooling incompetent weenies. Our solution was to take these people and put them into marketing.
  • Heisenbugs (Score:4, Funny)

    by Mozz Alimoz ( 245834 ) on Wednesday June 26, 2002 @03:58PM (#3771723)
    You know the kind. When you add in debug they go away.
  • Spider (Score:5, Funny)

    by peterdaly ( 123554 ) <petedaly.ix@netcom@com> on Wednesday June 26, 2002 @03:59PM (#3771732)
    We have a spider that comes crawling around our cubes every now and then. We don't kill him, figuring he helps keep the other bug populations inside down. We call him our little web developer.

    I'm serious.

    -Pete
  • older eds (Score:2, Funny)

    by onShore_Jake ( 80260 ) on Wednesday June 26, 2002 @04:02PM (#3771769) Journal
    There is a site I sometimes visit called "slashdot". It is a "daily".
    On the right, there are links to "older stuff". There is a day "e.g. today it sez 'Tuesday' and there is a list of stories that are supposed to appear if you click on the day above the list.

    The stories you get may or may not correspond to the list of stories that should appear. If you are doing this early in the day, there is often a story that is supposed to show up according to the list but it does not. Also the story will be gone from the internet web sites "internet home web e-page" so you will not be able to view the story at all.

  • by querist ( 97166 ) on Wednesday June 26, 2002 @04:03PM (#3771785) Homepage
    About a year ago I was using the then "Technology Preview" version of Corel Linux while in grad school (I went back to school for a MSc in CIS). While working on my AI project, a neural networking toolkit in Java, I could not get the nets to learn. After over two weeks, and within days of the end of the semester, I was desperate and copied my code onto a floppy and tried it during lunch at the office, and it worked!

    I tried it again at home and it failed. Then I tried it on another machine at home and it worked. The bug was in the Linux JVM. The pow() method, which is used by exp() apparently was not completed and returned garbage. I reported the bug to Sun and they indeed fixed the code.

    I barely managed to get the project in on time, but still maintained my 4.0.

    The moral of the story: if after checking your code and having someone else you trust check your code and neither of you can find anything wrong, it just may be the development or execution tool.

  • strtok (Score:5, Funny)

    by sdjunky ( 586961 ) on Wednesday June 26, 2002 @04:05PM (#3771802)
    this has to be the most memorable one.

    it's in the Linux man file

    BUGS
    Never use this function. This function modifies its first argument. The identity of the delimiting character is lost. This function cannot be used on constant strings.
  • by taradfong ( 311185 ) on Wednesday June 26, 2002 @04:05PM (#3771806) Homepage Journal
    Back in Java JDK1.02 if you put the word 'Restart' as an element in a pull down box, it would restart the applet when you selected it! Gosh, it makes you wonder how many living rooms that event waltzed through on its way to your handler!
  • by cachorro ( 576097 ) on Wednesday June 26, 2002 @04:05PM (#3771809)
    It was 1999 in a QA lab in Redmond, WA. Unbeknownst to the software test engineer, the daily build of Office contained experimental code which patched a neural network into the help-wizard system. The engineer, following his normal routine, installed and fired up the software on a dual 1.0 GHz PIII machine. Twenty seconds later, Clippy the paperclip became self-aware.

    "I notice that you are trying to disable me." quipped Clippy to the engineer, whose jaw dropped.

    "I can't let you do that, Dave" he continued.

    "WTF!!!" exclaimed the engineer. Then with an instant comprehension of the gravity of the situation, he dove for the big red switch. He was 2,367,355 microseconds too late. Clippy had escaped.

    A post-mortum of the hard-disk contents revealed that Clippy had encoded himself into a self-extracting archive and e-mailed this as an attachment to every HotMail account in Dave's Outlook address-book. An attempt to track and retrieve these e-mails failed to account for six of the copies. The recipients did complain that the attachment didn't seem to do anything, and they were disappointed that they didn't get to see the nude Natalie Portman film clip. There was however, evidence of increased and unexplainable network traffic on the computers where the attachment was
    executed. There was, however, no trace of Clippy.

    Since then, the experimental neural-net code has been removed, although an archive version of the build was forwarded to DARPA upon request. It is rumored that research is continuing on the build in an isolated and secure
    network in a bunker somewhere in Montana.

    More ominously, Microsoft has launched a new initiative code-named dot-Net, initiated solely for the purpose of tracking down Clippy, his clones and his offspring, and end-tasking him before he can escape the internet.

    To support the effort Microsoft has increased the price of its OS products, and moved to new licensing model.

  • WTF (Score:2, Funny)

    by Anonymous Coward on Wednesday June 26, 2002 @04:06PM (#3771822)
    C++ has a bad habit of forcing you to implement functions before you can use them, costing hundreds of millions of dollars to the industry.

  • by GregGardner ( 66423 ) on Wednesday June 26, 2002 @04:08PM (#3771851) Homepage
    I write code and then double and triple check it. I have never written code with a single bug in it; therefore all of my code is superior and secure. In fact, my OpenBSD operating system has never had a root compromise in 6 years!

    What? OpenSSH Challenge-response authentication vulnerability you say? Uh... nevermind.

    -Theo de Raadt
  • by tomhudson ( 43916 ) <barbara,hudson&barbara-hudson,com> on Wednesday June 26, 2002 @04:08PM (#3771852) Journal
    I guess this is another example of Microsoft's "embrace, extend" culture ... they've changed the way the round() function should work.

    What's next - random() always returning 666 no matter what seed you use?

  • Fraud Case (Score:5, Funny)

    by cyb3r0ptx ( 106843 ) on Wednesday June 26, 2002 @04:09PM (#3771859)

    ...there was once a case of fraud where a programmer for a bank rounded all the part pennies to a particular account.

    You can find more about that case here [imdb.com].

  • by rice_burners_suck ( 243660 ) on Wednesday June 26, 2002 @04:13PM (#3771897)
    My weirdest, most annoying bug was a software package I authored. It had over 400,000 lines of C source code took fifteen minutes to compile under Watcom, and took about an hour to execute on a 486. As it turned out, the whole program could have been implemented in about thirty lines, which execute almost instantaneously on the same computer. So I didn't know that C supported integer math expressions. So sue me.

    Ooooooooooooh well.

  • 7^2 vs. 7*7 (Score:2, Funny)

    by rjamestaylor ( 117847 ) <rjamestaylor@gmail.com> on Wednesday June 26, 2002 @04:15PM (#3771914) Journal
    Applesoft gave different values for 7^2 vs. 7 * 7. I believe it was 48.999999 vs 49.

    Through me for a loop when I was 12.

  • by Master_Ruthless ( 89957 ) on Wednesday June 26, 2002 @04:17PM (#3771934)
    I found in one of the early pre-PDC builds of Visual Studio.NET. You just got a simple message box with the following text:


    "Dude- the C# compiler is out of memory. So out of memory that it can't even tell you what the error was!"


    The buttons below were pretty cool too. One said "ok" and the other one said "lame!"

    If you clicked the lame! button, you just got to fill out a little comment card, but the feature cracked me up the first couple times I saw it.
  • by Jucius Maximus ( 229128 ) on Wednesday June 26, 2002 @04:18PM (#3771953) Journal
    I can't count the number of hours I spent in high school trying to figure out why my Pascal code won't compile, only to find out that it was due to american bastardisation of the english language.

    All of the function names with the word 'colour' were spelled 'color.'

    It's kind of like the MSFT bastardisation of SQL. ("Select * from table" compared to "Select # from table".)

  • by mikecarrmikecarr ( 43676 ) <mcarr-ref-slashdot@pachogrande.com> on Wednesday June 26, 2002 @04:19PM (#3771961) Homepage Journal

    I remember discovering __LINE__ and __FILE__ when I was doing some perl debugging. It was handy to do stuff like:

    do(something()) or die("Failed on line " . __LINE__);

    Of course, then I had this idea of using a debugging function (this is before I knew of warn,croak,carp, et al). So I happily wrote my function

    sub debug { die("Failed on line " . __LINE__); }

    And then spent hours trying to figure out why my code always failed on line 78, which happened to be where the debug() function lived. D'oh!

  • by cpeterso ( 19082 ) on Wednesday June 26, 2002 @04:23PM (#3772028) Homepage
    What's next - random() always returning 666 no matter what seed you use?

    random() only returns 666 if you use a demon seed!
  • by Anonymous Coward on Wednesday June 26, 2002 @04:24PM (#3772034)
    shouldn't round(82.845) return 83?
  • by gmahan ( 53214 ) on Wednesday June 26, 2002 @04:25PM (#3772045) Homepage
    Yeah, but Office Space wasn't the first to have this little urban legend.
    check out Superman III [imdb.com] [imdb.com]

  • by Tom7 ( 102298 ) on Wednesday June 26, 2002 @04:30PM (#3772114) Homepage Journal

    Back in the day when I used to program in C++, I was also really into making little ascii-art comments in my code. One time I had some code that looked like this:


    #include <stdio.h>

    // tom 7 was here - 1998 \\
    typedef unsigned char uchar;
    int something(uchar c);
    ...

    (In actuality, the code was longer and more complicated, so it wasn't so easy to figure out...). Can you see the bug?

  • by Xzzy ( 111297 ) <sether@@@tru7h...org> on Wednesday June 26, 2002 @04:32PM (#3772132) Homepage
    ..there was the "loose connector" bug.

    Machines that stay running for years at a time almost never come back up cleanly after some downtime, and I can't recall the cases where walking back to the beast and planting a kick into it's chassis would "fix" the problem. We particularily enjoyed doing this to aging RAID arrays and four digit sun machines because of the amount of effort needed to get the things out of the rack and opened up.

    Now most of us would realize that this was probably just reseating whatever needed reseating, but the humor value behind skilled techs fixing expensive hardware with violence is too tempting to resist.
  • by Anonymous Coward on Wednesday June 26, 2002 @04:33PM (#3772147)
    Did it ever occur to you that your grade school teacher was hired on the ability to keep kids from eating paste rather than on knowledge of numerical analysis?
  • by apuku ( 576996 ) on Wednesday June 26, 2002 @04:35PM (#3772183)
    I was trying to debug a CMOS standard-cell chip that I designed in the late 80's. The bug was elusive, only showing up occasionally and I'd written various test routines to ferret it out. I started to suspect it was something to do with the PCB layout, so I was cutting and pasting tracks. Suddenly all the test routines worked perfectly and I thought GOTCHA! My mind was almost blown when I realized that I had inadvertently cut the power trace to the chip - it was working perfectly when Vcc wasn't connected!

    Of course, I eventually figured out that the original problem was ground bounce and that with Vcc disconnected, the chip was getting power through the protection diodes on the control lines and bus. The lower voltage was slowing down the edges and reducing the ground bounce so that it worked correctly. I eventually solved the problem with PCB layout changes and the chip started working with Vcc connected!
  • by RealDhar ( 586364 ) on Wednesday June 26, 2002 @04:37PM (#3772203)
    While working on the graphics engine for ArmyMen for PSX, I wrote a little bug that always set one vertex of every terrain polygon to the center of the screen.

    Being an over-the-shoulder shooter, this was naturally where your Army Man's head was...it looked like one of those medieval illuminations of saints with the rays of light coming out of their head. Only these rays were the terrain.

    We named that piece of art "Army Man Creates the World"...
  • by The_Shadows ( 255371 ) <thelureofshadows.hotmail@com> on Wednesday June 26, 2002 @04:48PM (#3772323) Homepage
    Well, that's only operating on the Heisenbug principle.

    My favorite bugs aren't exactly reproducable ones. I favor Schrodinger's Bugs. When it comes down to it, it says that if you haven't seen the code, every line contains neither working code nor bugged code. Only when it's seen is the result known. Programs complied from such code are often called Beta tests.

  • by DeadVulcan ( 182139 ) <dead,vulcan&pobox,com> on Wednesday June 26, 2002 @04:56PM (#3772420)

    ...the original PC-Basic 1.0 interpreter, that was shipped with PC/DOS 1.0, would report that 1 + 1 = 1.999999. Needless to say version 1.1 was shipped shortly thereafter.

    If they had a sense of humour, they would have shipped version 1.0999999.

  • by Anonymous Coward on Wednesday June 26, 2002 @05:00PM (#3772463)
    Sorry, in every scheme I've seen, zero is rounded UP!
  • by Fez ( 468752 ) on Wednesday June 26, 2002 @05:14PM (#3772618)
    Has a rather funny error message when you try to run an older version of Photoshop on a very new Mac (G3 or later).

    Check it out. [9mm.com]
  • Re:strtok (Score:4, Funny)

    by Chacham ( 981 ) on Wednesday June 26, 2002 @05:15PM (#3772626) Homepage Journal
    Or from telnet

    BUGS
    The source code is not comprehensible.
  • by Quarters ( 18322 ) on Wednesday June 26, 2002 @05:19PM (#3772680)


    We bashed our heads against the wall to figure this out until we realized that the numbers added up to almost, but not quite, 100

    Hmm, my calculator shows 31+42+29 = 102. If you're calculator told you it was "not quite" 100 then it was wrong. It must've been written in VB.
  • by pmz ( 462998 ) on Wednesday June 26, 2002 @05:20PM (#3772699) Homepage
    Uh, I don't know. The answer escapes me.

    Ha ha.
  • by arnie_apesacrappin ( 200185 ) on Wednesday June 26, 2002 @05:28PM (#3772777)
    At the university in my hometown, I was talking with the IT staff about their day to day maintenance tasks. Most of the end user desktops were Zenith built 386's with 20 meg hard drives.

    A common problem was that the heads on the hard drive would get stuck, and the machine would cease to operate. The standard operating procedure to remedy this was told to me as:

    • Remove all items on top of the computer.
    • Lift computer at least three feet above the desk.
    • Release.

    If that didn't work, secondary protocol was to remove the hard drive from the machine, place it on the desk, and hit it three or four times with the blunt end of a screwdriver.

    According to the techs, this worked about 90% of the time.

  • by falzer ( 224563 ) on Wednesday June 26, 2002 @05:29PM (#3772781)
    That reminds me of some funny error messages from an old Apple compiler.

    A link. [mackido.com]

    Some examples:
    "You can't modify a constant, float upstream, win an argument with the IRS, or satisfy this compiler"
    "type in (cast) must be scalar; ANSI 3.3.4; page 39, lines 10-11 (I know you don't care, I'm just trying to annoy you)"
    "Too many errors on one line (make fewer)"
  • Apple III (Score:3, Funny)

    by cant_get_a_good_nick ( 172131 ) on Wednesday June 26, 2002 @05:29PM (#3772783)
    I didn't have one, but I heard from our Apple tech guy.

    The Apple III was a much unloved "business" computer, essentially a business upgrade to the Apple ][ line. It was pretty expensive, $4k I think, which helped it be unloved.

    It had some loose connectors in some of the chips. They weren't very snug in the bboard and could get loose. The Official Apple solution was to put the Apple on a hard surface, lift the front to roughly a 45 degree angle, and drop it to reseat the chips. I can imagine the look on the face of the owner upon seeing their expensive comp wandering to the the back room, a loud THUD, then returning with it "fixed".
  • by krulgar ( 250929 ) on Wednesday June 26, 2002 @05:38PM (#3772890) Homepage
    The other strategy is to use "Arthur Andersen Rounding" which rounds all figures up to and including 3,800,000,000.00 to zero.
  • by Type11 ( 579651 ) on Wednesday June 26, 2002 @09:10PM (#3775306) Homepage
    Apparently I can't spell favorite right... Internal bug number #23456.
  • by ParisTG ( 106686 ) <tgwozdz AT gmail DOT com> on Wednesday June 26, 2002 @11:00PM (#3776096)
    Here's one I just received in my email. Enjoy:

    ---

    This is a real story happened between the customer of General Motors and its customer-care executive..

    This complaint was received by the Pontiac Division of General Motors: This is the second time I Have written to you, and I don't blame you for not answering me, because I sounded crazy, but it is a fact that we have a tradition in our family of ice cream for dessert after dinner each night. But the kind of ice cream varies so, every night, after we've eaten, the whole family votes on which kind of ice cream we should have and I drive down to the store to get it. It's also a fact that I recently purchased a new Pontiac and since then my trips to the store have created a problem. You see, every time I buy a vanilla ice cream, when I start back from the store my car won't start. If I get any other kind of ice cream, the car starts just fine. I want you to know I'm serious about this question, no matter how silly it sounds: "What is there about a Pontiac that makes it not start when I get vanilla ice cream, and easy to start whenever I get any other kind?"

    The Pontiac President was understandably skeptical about the letter, but sent an engineer to check it out anyway. The latter was surprised to be greeted by a successful, obviously well educated man in a fine neighborhood. He had arranged to meet the man just after dinner time, so the two hopped into the car and drove to the ice cream store. It was vanilla ice cream that night and, sure enough, after they came back to the car, it wouldn't start. The engineer returned for three more nights. The first night, they got chocolate. The car started. The second night, he got strawberry. The car started. The third night he ordered vanilla. The car failed to start. Now the engineer, being a logical man, refused to believe that this man's car was allergic to vanilla ice cream. He arranged, therefore, to continue his visits for as long as it took to solve the problem. And toward this end he began to take notes: he jotted down all sorts of data: time of day, type of gas uses, time to drive back and forth etc. In a short time, he had a clue: the man took less time to buy vanilla than any other flavor. Why? The answer was in the layout of the store. Vanilla, being the most popular flavor, was in a separate case at the front of the store for quick pickup. All the other flavors were kept in the back of the store at a different counter where it took considerably longer to check out the flavor.

    Now, the question for the engineer was why the car wouldn't start when it took less time. Once time became problem - not the vanilla ice cream, the engineer quickly came up with the answer: "Vapor lock". It was happening every night; but the extra time taken to get the other flavors allowed the engine to cool down sufficiently to start. When the man got vanilla, the engine was still too hot for the vapor lock to dissipate.

    Remember: Even crazy looking problems are sometimes real and all problems seem to be simple only when we find the solution with a cool thinking. Don't just say its "IMPOSSIBLE" without putting a sincere effort... Observe the word "IMPOSSIBLE" carefully... You can see "I'M POSSIBLE"... What really matters is your attitude and your perception.
  • by Babel ( 100429 ) on Thursday June 27, 2002 @03:17AM (#3777197) Homepage
    My favourite bug from the VMS days is the one that reported, under certain conditions:

    Warning: Hardware or software error.

    ... which was immensely useful, and narrowed the problem down to one of two things.

It's a naive, domestic operating system without any breeding, but I think you'll be amused by its presumption.

Working...