~ubuntu-branches/ubuntu/hoary/courier/hoary

« back to all changes in this revision

Viewing changes to imap/imapscanclient.c

  • Committer: Bazaar Package Importer
  • Author(s): Thom May
  • Date: 2004-11-29 12:09:34 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20041129120934-kkn0xj11j0n1n6lo
Tags: 0.47-3ubuntu1
* Nathaniel McCallum
 - debian/*.init: pretty initscripts
 - debian/control: version depends on lsb-base

Show diffs side-by-side

added added

removed removed

Lines of Context:
59
59
#include        "imapwrite.h"
60
60
#include        "imapd.h"
61
61
 
62
 
static const char rcsid[]="$Id: imapscanclient.c,v 1.44 2004/04/21 01:09:15 mrsam Exp $";
 
62
static const char rcsid[]="$Id: imapscanclient.c,v 1.45 2004/07/19 23:54:14 mrsam Exp $";
63
63
 
64
64
static int do_imapscan_maildir2(struct imapscaninfo *, const char *,
65
65
                                int, int, struct uidplus_info *);
225
225
static int fnamcmp(const char *a, const char *b)
226
226
{
227
227
        long ai, bi;
 
228
        char ca, cb;
 
229
 
228
230
        ai = atol(a);
229
231
        bi = atol(b);
230
232
        if(ai - bi)
231
233
                return ai - bi;
232
 
        return strcmp(a, b);
 
234
 
 
235
        do
 
236
        {
 
237
                ca= *a++;
 
238
                cb= *b++;
 
239
 
 
240
                if (ca == ':') ca=0;
 
241
                if (cb == ':') cb=0;
 
242
        } while (ca && cb && ca == cb);
 
243
 
 
244
 
 
245
        return ( (int)(unsigned char)ca - (int)(unsigned char)cb);
233
246
}
234
247
 
235
248
static int sort_by_filename(struct tempinfo **a, struct tempinfo **b)