title: C Code how to change return address in the code?
body: <p>I just wrote a C Code which is below : </p>
  
  <pre><code>#include&lt;stdio.h&gt;
  #include&lt;string.h&gt;
  
  
  void func(char *str)
  {
          char buffer[24];
          int *ret;
          strcpy(buffer,str);
  }
  
  int main(int argc,char **argv)
  {
          int x;
          x=0;
          func(argv[1]);
          x=1;
          printf("\nx is 1\n");
          printf("\nx is 0\n\n");
  }
  </code></pre>
  
  <p>Can please suggest me as to how to skip the line <strong>printf("\nx is 1\n");</strong>. Earlier the clue which I got was to modify <strong><em>ret</em></strong> variable which is the return address of the function <strong>func</strong>.</p>
  
  <p>Can you suggest me as to how to change the return address in the above program so that <strong>printf("\nx is 1\n");</strong> is skipped.</p>
  
  <p>I have posted this question because I don't know how to change the return address.</p>
  
  <p>It would be great if you help me out.</p>
  
  <p>Thanks</p>