I can't. Name one.
Guy Lavi
Posts
-
The most creative log ever -
The most creative log everThis is "the pearl". His code contains many more of these gems.
-
The most creative log everExactly! :laugh:
-
The most creative log everObviously. Unfortunately he had enough time to wreck havoc in the company code base.
-
The most creative log everFrom that day on, whenever i need to get into this person code, i start pounding my head on the wall (literally) and swear. My boss then calls from the next office: "is it ###### code again?" X|
-
The most creative log everWhen I started working in my current position four years ago, I inherited a system full of bugs and was given the task to iron out all of the bugs. The first step i though would be to turn on the logger and try to find out where and when the crashes happen. I turned on the logger and after a few minutes... BIG MISTAKE! My system crashed. It took me 2 days to re-install everything, and turn on the logger again. and it happened again. The next time i was smarter, and ghosted my disk. I also finally found the correct source code version (which was hidden among multiple copies of various versions and test made by the person), and run it through a debugger. and then i found out this little beauty:
public void errorCatcher(string msg)
{
RegistryKey key = Registry.CurrentUser.OpenSubKey(KEY_NAME_START + @"\errors", true);
if (key != null)
{
key.SetValue(DateTime.Now.ToString(), msg);
key.Close();
}
}and every method in the system had the same reference in it's catch clause:
catch (Exception exception) { errorCatcher(exception.ToString()); return ""; }
I took me two weeks to rewrite the whole thing, throw away 90% of the code, and roll out a bug free system. (I still keep the original code as proof, as no one believes me when i tell people about it.)
-
How old were you when you first wrote a line of code ?Well said! That's why i switched to assembly when i got bored of moving asterisks around. I needed to outsmart my friends and move ALL of the characters on the screen. Made a nice wheel of all of them.
-
How old were you when you first wrote a line of code ?I was 8, and it was Basic. Right afterwards I started messing with Assembly. Yes. Weird kid.