title: using gdb effectively
body: <p>I'm used to using gdb quite effectively when I am dealing with ELF binaries which have been compiled using the -ggdb flag. However there are a few difficulties I am facing when I am facing <code>normal non-stripped</code> binaries.</p>
  
  <ol>
  <li>I can set the breakpoint at main, but what if I needed to set the breakpoint at a fixed offset(say 10 lines) from the start of main?</li>
  <li>Usually I get the address of a character array(say <code>buf</code>) as <code>print &amp;buf</code>. However, in the current case I get a message saying that <code>buf</code> cannot be found in the current context.</li>
  </ol>
  
  <p>How do I deal with the above mentioned issues? It would be great if you could provide some reading material too.</p>