Now this is embarassing
-
if (_Uptime != null)
{
_Uptime.Remove(TraCommon.Tokens.TraService_Speed);
}
{
_Uptime = new Service.Message();
_Uptime.Code = SysCommon.CommandCode.SysUptimeEvt;
}I just found this in my code. It's been there for years.
Software Zen:
delete this;
:laugh: It took me a while... and even that I haven't written a line of code in years, I found the mistake. This is the reason why I started coding "if" constructs (and the like) with empty bodies even when they where short.
if()
{
}
else
{
}Only after that I filled in what had to be filled in.
-
if (_Uptime != null)
{
_Uptime.Remove(TraCommon.Tokens.TraService_Speed);
}
{
_Uptime = new Service.Message();
_Uptime.Code = SysCommon.CommandCode.SysUptimeEvt;
}I just found this in my code. It's been there for years.
Software Zen:
delete this;
That is cool. What else have you been upto these past years?
WP7.5 Apps - XKCD | Calvin | SMBC | Sound Meter | Speed Dial
-
Embarassing2A: We use SourceSafe. Embarassing2B: It would still tell you that it really is.
Software Zen:
delete this;
You could always lie and say the blame was falsely attributed due to corruption.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason? Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful? --Zachris Topelius Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies. -- Sarah Hoyt
-
You could always lie and say the blame was falsely attributed due to corruption.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason? Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful? --Zachris Topelius Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies. -- Sarah Hoyt
Embarassing3: I'm the SourceSafe *cough* data base *cough* admin, which means I'm responsible for ensuring the integrity of our source control system. Besides, this is far from the worst bug I've ever fixed that had been around for a while.
Software Zen:
delete this;
-
That is cool. What else have you been upto these past years?
WP7.5 Apps - XKCD | Calvin | SMBC | Sound Meter | Speed Dial
Writing a whole lot of C# that, while it makes FxCop whine like a teenager when the mall closes early, works remarkably well.
Software Zen:
delete this;
-
Embarassing3: I'm the SourceSafe *cough* data base *cough* admin, which means I'm responsible for ensuring the integrity of our source control system. Besides, this is far from the worst bug I've ever fixed that had been around for a while.
Software Zen:
delete this;
That should make it even easier to "fix". :-\
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason? Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful? --Zachris Topelius Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies. -- Sarah Hoyt
-
if (_Uptime != null)
{
_Uptime.Remove(TraCommon.Tokens.TraService_Speed);
}
{
_Uptime = new Service.Message();
_Uptime.Code = SysCommon.CommandCode.SysUptimeEvt;
}I just found this in my code. It's been there for years.
Software Zen:
delete this;
-
etkins wrote:
will lint catch that error
I doubt it. There's nothing to differentiate this case from a normal
if
statement followed by a scope block.Software Zen:
delete this;
-
Writing a whole lot of C# that, while it makes FxCop whine like a teenager when the mall closes early, works remarkably well.
Software Zen:
delete this;
I like the comparison of FxCop whinging like a teenager... :)
WP7.5 Apps - XKCD | Calvin | SMBC | Sound Meter | Speed Dial
-
if (_Uptime != null)
{
_Uptime.Remove(TraCommon.Tokens.TraService_Speed);
}
{
_Uptime = new Service.Message();
_Uptime.Code = SysCommon.CommandCode.SysUptimeEvt;
}I just found this in my code. It's been there for years.
Software Zen:
delete this;
It 's OK to code like this It was supposed to various _Uptime get the instance in the "{ xxx }" :-D :-D