git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] New strbuf APIs: splice and attach.

From
FWFlorian Weimer <fw@deneb.enyo.de>
Date
Sep 17, 2007, 05:43 UTC
Message-ID
<87myvlzw1p.fsf@mid.deneb.enyo.de>
In-Reply-To
<20070916205136.GE26457@artemis.corp>
* Pierre Habouzit:
Show 11 quoted lines
> On Sun, Sep 16, 2007 at 08:20:06PM +0000, Florian Weimer wrote:
>> * Pierre Habouzit:
>> 
>> > +void strbuf_grow(struct strbuf *sb, size_t extra)
>> > +{
>> >  	if (sb->len + extra + 1 <= sb->len)
>> >  		die("you want to use way too much memory");
>> 
>> By the way, this comparison is always false because sb->len is signed.
>
>   News to me. Actually it's not, it's a size_t :)
Ah, then this has changed somewhere.  It used to be int.  Good.
Previous: Pierre HabouzitNext: Pierre Habouzit
Message 13 of 21 in “[RFC] strbuf's in builtin-apply”
  1. Pierre HabouzitSep 15, 2007
  2. New strbuf APIs: splice and embed.Pierre Habouzit, Sep 15, 2007
  3. Junio C HamanoSep 16, 2007
  4. Pierre HabouzitSep 16, 2007
  5. builtin-apply: use strbuf's instead of buffer_desc's.Pierre Habouzit, Sep 15, 2007
  6. Junio C HamanoSep 16, 2007
  7. Pierre HabouzitSep 16, 2007
  8. Pierre HabouzitSep 15, 2007
  9. Pierre HabouzitSep 16, 2007
  10. New strbuf APIs: splice and attach.Pierre Habouzit, Sep 15, 2007
  11. Florian WeimerSep 16, 2007
  12. Pierre HabouzitSep 16, 2007
  13. Florian WeimerSep 17, 2007
  14. Now that cache.h needs strbuf.h, remove useless includes.Pierre Habouzit, Sep 15, 2007
  15. Refactor replace_encoding_header.Pierre Habouzit, Sep 15, 2007
  16. Remove preemptive allocations.Pierre Habouzit, Sep 16, 2007
  17. Rewrite convert_to_{git,working_tree} to use strbuf's.Pierre Habouzit, Sep 16, 2007
  18. Linus TorvaldsSep 16, 2007
  19. builtin-apply: use strbuf's instead of buffer_desc's.Pierre Habouzit, Sep 16, 2007
  20. Pierre HabouzitSep 16, 2007
  21. Junio C HamanoSep 16, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.