Loading ...
Sorry, an error occurred while loading the content.

Re: Patch: prevent certain cscope errors from locking up vim

Expand Messages
  • Bram Moolenaar
    ... That looks like a good idea. EMSG2() only handles two arguments though. I ll add emsg3() for this. -- login: yes password: I don t know, please tell me
    Message 1 of 7 , Feb 1, 2004
    • 0 Attachment
      Gary Johnson wrote:

      > As I was looking at this some more I realized that while this works,
      > having all these #ifdef's really muddies the code. I've also
      > noticed that perror() is used in other source files as well. So I
      > would like to propose that a PERROR() macro be added to vim.h,
      > perhaps like this:
      >
      > #ifdef HAVE_STRERROR
      > # define PERROR(msg) (void)EMSG2("%s: %s", msg, strerror(errno))
      > #else
      > # define PERROR(msg) perror(msg)
      > #endif
      >
      > and that all the calls to perror() be changed to use PERROR()
      > instead, at least where it is appropriate to use EMSG2().

      That looks like a good idea. EMSG2() only handles two arguments though.
      I'll add emsg3() for this.

      --
      login: yes
      password: I don't know, please tell me
      password is incorrect
      login: yes
      password: incorrect

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
      \\\ Project leader for A-A-P -- http://www.A-A-P.org ///
      \\\ Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html ///
    Your message has been successfully submitted and would be delivered to recipients shortly.