I can't find much of anything particularly interesting about this link. Is there a fix for this bug? Discussion about what causes it? I did a search and couldn't find anything really useful about this. Maybe a break down of the troubleshooting involved behind locating this bug, now that'd be interesting.
Yes. The while statement can't take variable arguments. Also, ellipsis is not a standalone expression. Also, if "fileSize" is exactly 8192 then ellipsis will execute because "bytesRemaining" will equal zero. If your compiler actually compiles ellipsis and "fileSize" is exactly 8192, then something bad will probably happen. Either the undefined behavior of the compiled ellipses or the unexpected negative number will likely cause a crash.
I remember dealing with this when I first started developing. One of my senior developers thought it had to do with some kind of semicolon thresholds. Mainly because it more often than not happened in his CSS files. The solution is easy. Just add another comment and you'll surpass the 8kb size and be fine.
Let me guess. 8192 byte buffer and assumption in code that <=0 [byte count/-1 error] from read() means read error.
Sometimes you will get zero bytes read return values. Like when there really isn't a byte more to read. So zero bytes available doesn't signal an error.
I'd love to know what's corrupting their cache. That the response is "delete the cache and profile" is rather pathetic for an expensive program like Dreamweaver.
If you want to sell your product as closed source, IMO you should put something into place to detect corruption, or at least diagnose how it occurs.
Even worse is that this whole article is about workarounds... Unless I'm mistaken, these seem to be known issues - will Adobe be making fixes? I'm fairly certain that an 8kb bug should be fixed pretty easily.
Ah, this takes me back to my Dreamweaver days. I remember when it wouldn't let me edit a file unless I deleted a certain Dreamweaver configuration file that wasn't quite working correctly. I'm not sure why Dreamweaver couldn't just delete the file itself, but it was a real pain having to find the file and delete it so Dreamweaver could re-generate it again.
The interestingess of a bug is not necessarilly related to the release date of the program it appears in.
It's interesting as a classic example of an off-by-one bug, one that happens in seemingly strange conditions (8K multiples), and one that affected a major product from a big company.
27 comments
[ 3.0 ms ] story [ 67.9 ms ] threadSo not simply 8kb as the (current) title states.
P(filesize is multiple of 8192 | crashed) = P(crashed | filesize is multiple of 8192) * P(filesize is multiple of 8192)/P(crashed)
Where:
- The likelihood of crashing given the filesize is a multiple of 8192 is 1;
- The naïve prior of the filesize being a multiple of 8192 is 1/8192;
The task is now to estimate the probability P(crashed), which is the probability the program will crash for whatever reason.
Edit: I guess that was funnier in my head.
Sometimes you will get zero bytes read return values. Like when there really isn't a byte more to read. So zero bytes available doesn't signal an error.
If you want to sell your product as closed source, IMO you should put something into place to detect corruption, or at least diagnose how it occurs.
Even worse is that this whole article is about workarounds... Unless I'm mistaken, these seem to be known issues - will Adobe be making fixes? I'm fairly certain that an 8kb bug should be fixed pretty easily.
Another reminder to always test the edge cases (as though we needed another :) ).
http://www.adobe.com/uk/products/dreamweaver/features.html
Maybe there's something interesting about it, but I fail to see what is so special about this bug.
It's interesting as a classic example of an off-by-one bug, one that happens in seemingly strange conditions (8K multiples), and one that affected a major product from a big company.