Aren&#39;t the strings split at newline characters? If not, then a text file would usually simply be one giant string....<br><br><div><br><div class="gmail_quote">On Fri, Jul 9, 2010 at 7:33 AM, Johny <span dir="ltr">&lt;<a href="mailto:Johny.Jose@cern.ch">Johny.Jose@cern.ch</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">


  

<div text="#000000" bgcolor="#ffffff"><div><div></div><div class="h5">
On 07/09/2010 01:27 PM, David Cole wrote:
<blockquote type="cite">Are some of the lines empty by any chance?
  <div><br>
  </div>
  <div>Empty elements are not iterated in a foreach of a list.</div>
  <div><br>
  </div>
  <div>Nor (I would expect, I have not verified) is an empty string
considered a string for reporting by file(STRINGS ...</div>
  <div><br>
  <br>
  </div>
  <div>HTH,</div>
  <div>David</div>
  <div><br>
  </div>
  <div><br>
  <div class="gmail_quote">On Fri, Jul 9, 2010 at 5:24 AM, Johny <span dir="ltr">&lt;<a href="mailto:Johny.Jose@cern.ch" target="_blank">Johny.Jose@cern.ch</a>&gt;</span>
wrote:<br>
  <blockquote class="gmail_quote" style="border-left:1px solid rgb(204, 204, 204);margin:0pt 0pt 0pt 0.8ex;padding-left:1ex">Hi,<br>
    <br>
I was working with the FILE(STRINGS filename lineList) and i discovered
that i end up getting a list which has a lesser number of strings than
the actual lines in the file. However this happens with only some
files, i went through those but they seem to be regular files. When i
count the no of new lines in the files i get the correct no of lines
for the file.<br>
    <br>
This has led me to believe that the FILE strings command is at fault
somehow. How does it work?<br>
    <br>
Cheers!<br>
    <font color="#888888">Johny</font>
    <div>
    <div><br>
    <br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
    <br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
    <br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
    <br>
Follow this link to subscribe/unsubscribe:<br>
    <a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br>
    </div>
    </div>
  </blockquote>
  </div>
  <br>
  </div>
</blockquote></div></div>
Is&#39;nt an empty line a newline character ? if thats it then the file in
question has plenty of them. I guess thats the reason then. <br>
<br>
Cheers!<br>
Johny<br>
</div>

</blockquote></div><br></div>