Thread (4 messages) flat view 4 messages, 2 authors, 2007-01-04

Re: [PATCH 1/1] determine last ext3 LBA to fix wild LBA reads - v2

From: Doug Maxey <hidden>
Date: 2007-01-04 02:11:21

On Thu, 04 Jan 2007 12:09:16 +1100, Benjamin Herrenschmidt wrote:
quoted
      tempb = (((unsigned long long) block) *
 	      ((unsigned long long)bs)) + (unsigned long long)doff;
+     if (tempb > dend) {
+	  DEBUG_F("\nSeek error on block %lx, tempb=%Lx\n", block, tempb >> 9);
+	  return EXT2_ET_LLSEEK_FAILED;
+     }
+
In the case where we don't pass a "part", dend is 0 no ? We should check
this case and not apply the test...
well, I guess we should not test in that case.  (dend && tempb >> dend)
But that puts us back in the position of searching past the end of the 
disk.

On what system would we get here without having found a partition table?
Ext2 on a optical disk?

++doug
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help