On Fri, 28 Oct 2011 23:59:30 +0300, Jani Nikula <[email protected]> wrote:
> @@ -412,6 +413,14 @@ notmuch_search_command (void *ctx, int argc, char 
> *argv[])
>               fprintf (stderr, "Invalid value for --sort: %s\n", opt);
>               return 1;
>           }
> +     } else if (STRNCMP_LITERAL (argv[i], "--maxitems=") == 0) {
> +         const char *p;
> +         opt = argv[i] + sizeof ("--maxitems=") - 1;
> +         maxitems = strtoul(opt, &p, 10);

p should be of type `char *', not `const char *', as it will be
modified by strtoul. (Otherwise, gcc will produce a warning about this).

Cheers,
Daniel

Attachment: pgpjX7J5cST8t.pgp
Description: PGP signature

_______________________________________________
notmuch mailing list
[email protected]
http://notmuchmail.org/mailman/listinfo/notmuch

Reply via email to