Any pointers on how I can force the first message to be pointed to
irrespective of the conditions?
Thanks,
Praveen
I got a little too frustrated with this issue and deleted the .pinerc
and recreated .pinerc by running alpine. I moved some of my important
settings to the new .pinerc. Now alpine seems to work alright. Seems
like the feature-list carried out from pine to alpine is likely to be
the reason.
Thanks,
Praveen
Alas! I spoke too soon.. Still I see the same behavior. I move my
mails from the inbox to sub-folders using "save" and could this be a
reason ?
Praveen
Ok. I looked at the alpine code a little bit and found out
first_sorted_flagged() returns the wrong value when IS_FLAG is set. I
believe there should be an FSF_FIRST option that can avoid the
function loops as well and just return 1.
scenario.
IMAP incoming folder sort order - Reverse arrival
Incoming-startup-rule = first
New mail comes in. Unread, save it to an imap folder
open the imap folder, the cursor is at the last message.. should have
been the first
Praveen
> Ok. I looked at the alpine code a little bit and found out
> first_sorted_flagged() returns the wrong value when IS_FLAG is set. I
> believe there should be an FSF_FIRST option that can avoid the
> function loops as well and just return 1.
>
> scenario.
> IMAP incoming folder sort order - Reverse arrival
> Incoming-startup-rule = first
> New mail comes in. Unread, save it to an imap folder
> open the imap folder, the cursor is at the last message.. should have
> been the first
>
> Praveen
Some debug from this might be revealing. Try running with flags
-d verbose=9,imap=4,flush
and you should see something like
imap_cmd(testfolder, SEARCH, 0x1)
IMAP DEBUG 14:30:45 8/26: 0000000d SEARCH UNDELETED
IMAP DEBUG 14:30:45 8/26: * SEARCH 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
IMAP DEBUG 14:30:45 8/26: 0000000d OK SEARCH completed
First_sorted_flagged returning winner = 1
which is how it locates the first undeleted message. I'd be careful
special-casing away some of the calls because there may be side-effects
that are needed. I don't know I'm just saying there may be.
I haven't been able to reproduce the problem you are having, maybe the
debug output will show why. Thanks.
Steve