Jon Smirl wrote:
On 7/28/05, Mitchell Blank Jr <[email protected]> wrote:[...] It looks sane-ish to me, but also more complicated than need be. Why can't you just do something like: while (count > 0 && isspace(x[count - 1])) count--;Do we need to deal with UTF8 here? I did the forward loop because you can't parse UTF8 backwards. If UTF8 is possible I need to change the pointer inc function.
I don't think it matters here. Even with UTF8, any char that makes isspace return true, can't be part of a multi-byte char, as every byte in a multi-byte char in UTF8 has the MSB set, i.e., >= 0x80.
-- Paulo Marques - www.grupopie.com It is a mistake to think you can solve any major problems just with potatoes. Douglas Adams - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- References:
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Greg KH <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Greg KH <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Jon Smirl <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Jon Smirl <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Greg KH <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Jon Smirl <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Greg KH <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Jon Smirl <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Greg KH <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Mitchell Blank Jr <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- From: Jon Smirl <[email protected]>
- Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- Prev by Date: Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- Next by Date: 2.4.32-pre2: uhci.c: ff80: host controller halted. very bad
- Previous by thread: Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- Next by thread: Re: [PATCH] driver core: Add the ability to unbind drivers to devices from userspace
- Index(es):