<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Ian Winter &#187; bugs</title>
	<atom:link href="http://ianwinter.co.uk/tag/bugs/feed/" rel="self" type="application/rss+xml" />
	<link>http://ianwinter.co.uk</link>
	<description>Have you found the instructions yet?</description>
	<lastBuildDate>Wed, 14 Sep 2011 22:16:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>ColdFusion Leap Year Fun</title>
		<link>http://ianwinter.co.uk/2008/03/09/coldfusion-leap-year-fun/</link>
		<comments>http://ianwinter.co.uk/2008/03/09/coldfusion-leap-year-fun/#comments</comments>
		<pubDate>Sun, 09 Mar 2008 15:18:00 +0000</pubDate>
		<dc:creator>Ian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[coldfusion]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[So just an update on this. I sent off some emails to folks at Adobe and have had acknowledgment but as yet no reply. I&#8217;ll you know if and when I get something back.]]></description>
			<content:encoded><![CDATA[<p>So just an update on this. I sent off some emails to folks at Adobe and have had acknowledgment but as yet no reply. I&#8217;ll you know if and when I get something back.</p>
]]></content:encoded>
			<wfw:commentRss>http://ianwinter.co.uk/2008/03/09/coldfusion-leap-year-fun/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Coldfusion possible Leap Year bug</title>
		<link>http://ianwinter.co.uk/2008/02/28/coldfusion-possible-leap-year-bug/</link>
		<comments>http://ianwinter.co.uk/2008/02/28/coldfusion-possible-leap-year-bug/#comments</comments>
		<pubDate>Thu, 28 Feb 2008 10:11:00 +0000</pubDate>
		<dc:creator>Ian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[coldfusion]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[My colleague noticed that as of midnight GMT one of our applications at work broke. After some digging it looks like a CF leap year bug. The code was run on CF 7.0.1, 7.0.2 &#038; 8.0.0 on Windows and Linux, all produce same results. Not sure for definite it&#8217;s a bug, but, it&#8217;s always worked [...]]]></description>
			<content:encoded><![CDATA[<p>My colleague noticed that as of midnight GMT one of our applications at work broke. After some digging it looks like a CF leap year bug.</p>
<pre class="brush: coldfusion; title: ; notranslate">
&lt;cfset attributes.minage = 18&gt;
&lt;cfoutput&gt;
#now()#&lt;br /&gt;
#attributes.minage#&lt;br /&gt;
#dateadd(&quot;yyyy&quot;, -(attributes.minage), now())#&lt;br /&gt;
#datediff(&quot;yyyy&quot;, dateadd(&quot;yyyy&quot;, -(attributes.minage), now()), now())#&lt;br /&gt;
#datediff(&quot;yyyy&quot;, dateadd(&quot;yyyy&quot;, -(attributes.minage), now()), DateAdd(&quot;d&quot;, 1, now()))#
&lt;/cfoutput&gt;
</pre>
<p>The code was run on CF 7.0.1, 7.0.2 &#038; 8.0.0 on Windows and Linux, all produce same results.</p>
<p>Not sure for definite it&#8217;s a bug, but, it&#8217;s always worked until today, in theory it might work again tomorrow as well. Last leap year of course was CF6 so may not have shown up.</p>
<p>Yay for dateDiff()&#8230; <img src='http://ianwinter.co.uk/wp-includes/images/smilies/icon_neutral.gif' alt=':|' class='wp-smiley' /> </p>
<p><em>Update</em></p>
<p>A more detailed example. It only effects the 28/2. Other dates fine suggesting more that it&#8217;s leap year related.</p>
<pre class="brush: coldfusion; title: ; notranslate">
&lt;cfoutput&gt;
	&lt;cfset variables.datea = createDate(2008,02,3)&gt;
	&lt;cfloop from=&quot;2008&quot; to=&quot;1990&quot; step=&quot;-1&quot; index=&quot;variables.y&quot;&gt;
		&lt;cfset variables.dateb = createDate(variables.y,02,3)&gt;
		&lt;cfset variables.diff = datediff(&quot;yyyy&quot;, variables.datea, variables.dateb)&gt;
		#variables.datea# - #variables.dateb# = #variables.diff#&lt;br /&gt;
	&lt;/cfloop&gt;
&lt;/cfoutput&gt;
</pre>
<p>And it&#8217;s output&#8230;.</p>
<pre class="brush: plain; title: ; notranslate">
{ts '2008-02-28 00:00:00'} - {ts '2008-02-28 00:00:00'} = 0
{ts '2008-02-28 00:00:00'} - {ts '2007-02-28 00:00:00'} = 0
{ts '2008-02-28 00:00:00'} - {ts '2006-02-28 00:00:00'} = -1
{ts '2008-02-28 00:00:00'} - {ts '2005-02-28 00:00:00'} = -2
{ts '2008-02-28 00:00:00'} - {ts '2004-02-28 00:00:00'} = -4
{ts '2008-02-28 00:00:00'} - {ts '2003-02-28 00:00:00'} = -4
{ts '2008-02-28 00:00:00'} - {ts '2002-02-28 00:00:00'} = -5
{ts '2008-02-28 00:00:00'} - {ts '2001-02-28 00:00:00'} = -6
{ts '2008-02-28 00:00:00'} - {ts '2000-02-28 00:00:00'} = -8
{ts '2008-02-28 00:00:00'} - {ts '1999-02-28 00:00:00'} = -8
{ts '2008-02-28 00:00:00'} - {ts '1998-02-28 00:00:00'} = -9
{ts '2008-02-28 00:00:00'} - {ts '1997-02-28 00:00:00'} = -10
{ts '2008-02-28 00:00:00'} - {ts '1996-02-28 00:00:00'} = -12
{ts '2008-02-28 00:00:00'} - {ts '1995-02-28 00:00:00'} = -12
{ts '2008-02-28 00:00:00'} - {ts '1994-02-28 00:00:00'} = -13
{ts '2008-02-28 00:00:00'} - {ts '1993-02-28 00:00:00'} = -14
{ts '2008-02-28 00:00:00'} - {ts '1992-02-28 00:00:00'} = -16
{ts '2008-02-28 00:00:00'} - {ts '1991-02-28 00:00:00'} = -16
{ts '2008-02-28 00:00:00'} - {ts '1990-02-28 00:00:00'} = -17
</pre>
]]></content:encoded>
			<wfw:commentRss>http://ianwinter.co.uk/2008/02/28/coldfusion-possible-leap-year-bug/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ColdFusion structure Bug</title>
		<link>http://ianwinter.co.uk/2006/10/26/coldfusion-structure-bug/</link>
		<comments>http://ianwinter.co.uk/2006/10/26/coldfusion-structure-bug/#comments</comments>
		<pubDate>Thu, 26 Oct 2006 09:44:00 +0000</pubDate>
		<dc:creator>Ian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[coldfusion]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Found a new bug today in Coldfusion 7. Basically if you create structure via arguments and try to use it later you&#8217;ll notice some funky behaviour and the meta information about the structure is incorrect. Code test case is included. &#60;cfscript&#62; function struct() { return arguments; } &#60;/cfscript&#62; &#60;cfset s = struct(arg1=&#8220;blahblah&#8221;, arg2=&#8220;cont&#8221;, arg3=&#8220;act&#8221;)&#62; &#60;cfoutput&#62; [...]]]></description>
			<content:encoded><![CDATA[<p>Found a new bug today in Coldfusion 7. Basically if you create structure via arguments and try to use it later you&#8217;ll notice some funky behaviour and the meta information about the structure is incorrect. Code test case is included.</p>
<div class="code"><font COLOR=MAROON>&lt;cfscript&gt;</font><br />
    function struct() { return arguments; } <font COLOR=MAROON>&lt;/cfscript&gt;</font></p>
<p><font COLOR=MAROON>&lt;cfset s = struct(arg1=</font><font COLOR=BLUE>&#8220;blahblah&#8221;</font>, arg2=<font COLOR=BLUE>&#8220;cont&#8221;</font>, arg3=<font COLOR=BLUE>&#8220;act&#8221;</font>)&gt;</p>
<p><font COLOR=MAROON>&lt;cfoutput&gt;</font><br />
    <font COLOR=NAVY>&lt;h3&gt;</font>#s.getClass()#<font COLOR=NAVY>&lt;/h3&gt;</font><br />
    length: #structcount(s)# (#structkeylist(s)#)<font COLOR=NAVY>&lt;br&gt;</font><br />
    <font COLOR=MAROON>&lt;cfset structdelete(s, &#8216;arg1&#8242;)&gt;</font><br />
    length: #structcount(s)# (#structkeylist(s)#)<font COLOR=NAVY>&lt;br&gt;</font><br />
    <font COLOR=MAROON>&lt;cfset structdelete(s, &#8216;arg2&#8242;)&gt;</font><br />
    length: #structcount(s)# (#structkeylist(s)#) <font COLOR=MAROON>&lt;/cfoutput&gt;</font></p>
<p><font COLOR=MAROON>&lt;cfset s = structnew()&gt;</font><br />
<font COLOR=MAROON>&lt;cfset s['arg1'] = </font><font COLOR=BLUE>&#8220;blahblah&#8221;</font>&gt;<br />
<font COLOR=MAROON>&lt;cfset s['arg2'] = </font><font COLOR=BLUE>&#8220;cont&#8221;</font>&gt;<br />
<font COLOR=MAROON>&lt;cfset s['arg3'] = </font><font COLOR=BLUE>&#8220;act&#8221;</font>&gt;</p>
<p><font COLOR=MAROON>&lt;cfoutput&gt;</font><br />
    <font COLOR=NAVY>&lt;h3&gt;</font>#s.getClass()#<font COLOR=NAVY>&lt;/h3&gt;</font><br />
    length: #structcount(s)# (#structkeylist(s)#)<font COLOR=NAVY>&lt;br&gt;</font><br />
    <font COLOR=MAROON>&lt;cfset structdelete(s, &#8216;arg1&#8242;)&gt;</font><br />
    length: #structcount(s)# (#structkeylist(s)#)<font COLOR=NAVY>&lt;br&gt;</font><br />
    <font COLOR=MAROON>&lt;cfset structdelete(s, &#8216;arg2&#8242;)&gt;</font><br />
    length: #structcount(s)# (#structkeylist(s)#) <font COLOR=MAROON>&lt;/cfoutput&gt;</font></div>
]]></content:encoded>
			<wfw:commentRss>http://ianwinter.co.uk/2006/10/26/coldfusion-structure-bug/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

