Re: [PATCH] compat: add memrchr()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 15, 2010 at 05:17, Jonathan Nieder <jrnieder@xxxxxxxxx> wrote:
> Reimplement another handy convenience function from glibc. Âmemrchr()
> searches from the end of a memory area for a particular character. ÂIt
> is similar to strrchr() but takes a length argument and is
> binary-safe.
>
> The whole-directory rename detection patch could use this to find the
> last directory separator in a (possibly truncated) pathname.

Maybe something like this for configure.ac:

    AC_CHECK_LIB([c], [memchr],
    [HAVE_MEMRCHR=YesPlease],
    [HAVE_MEMRCHR=])
    AC_SUBST(HAVE_MEMRCHR)

And documentation with the other HAVE_* variables at the top of the
Makefile?
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]