Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Bug stories!

Name: Anonymous 2014-02-06 22:31

This is a thread where we tell our stories of bugs that we fixed or couldn't fix.

I'll start:
I'm making an OpenGL program in sepples and I was trying to glGetString(GL_VERSION) so I can see if everything is working on Windows.

Every time I even made a function call? My program would crash. I couldn't for the love of my life find this god damn bug and started shouting and planning to plant pipebombs at Microsoft.[1]

Turns out I made a global object which when instantiated would call that function from it's constructor. It seemed reasonably appropriate to place that function call there for the moment since I'd remove it later.

When you don't have an OpenGL context? Any OpenGL function calls you make result in undefined behavior; read: program crash.

Your turn.

[1] Not actually. Although I should make a 'pipebomb microsoft to hell' doom clone.

Name: Anonymous 2014-02-07 5:32

As someone who works with ENTERPRISE Java, I've actually seen this construction more than once, written once in-house and once in a third-party library, as the root cause of the symptom ``Gee, why is our program dying on startup but not writing out any logs?''

public class SomeFuckingThing {

...

public static void setUpShit() {
try {
theGlobalErrorLogger = new GlobalErrorLogger("/hardcoded/path/to/configuration/file.xml");
} catch (IHandlePropertiesFilesLikeAMoronError ex1) {
dieWithNicelyFormattedError("Could not instantiate error logging", ex1);
}
}

...

public static void dieWithNicelyFormattedError(String text, Throwable cause) {
theGlobalErrorLogger.logFatalError(text, cause);
System.exit(0);
}

...

}

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List