Re: [binc] NOOP fails (from time to time)

Peter Stuge <[email protected]>
Newsgroups gmane.mail.imap.binc.general
Message-ID <[email protected]>
On Mon, May 23, 2005 at 02:19:55PM +0200, Jerry Lundström wrote:
> >>>Unfortunately this strace output isn't useful. This is the
> >>>strace of either tcpserver or bincimap-up and we need the strace
> >>>from bincimapd.
> >
> >And just to rereply, here's a patch I'd like you to try:
> 
> Very easy replicated error:

Thanks Jerry!


> 1 CLOSE
> 1 OK CLOSE completed
> 1 NOOP
> * BYE Invalid Mailbox, /new/: No such file or directory

This is caused by line 81 in maildir-close.cc;
  path = "";

path is initialized in session-initialize-bincimapd.cc by this code:

  string path = session.globalconfig["Mailbox"]["path"];
  if (session.args.getUnqualifiedArgs().size() > 0)
    path = session.args.getUnqualifiedArgs()[0];
  if (path == "") path = ".";
  else if (chdir(path.c_str()) != 0) {
    mkdir(path.c_str(), 0777);
    if (chdir(path.c_str()) != 0) {
      logger << "when entering depot " + toImapString(path) + ": "
             << strerror(errno) << endl;
      return false;
    }
  }

..and I guess it should be re-initialized after a CLOSE.


//Peter
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.