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

Re: [PATCH] defaults for where to merge from (take 3, inline)

From
Paolo Bonzini <paolo.bonzini@gmail.com>
Date
Mar 2, 2007, 08:10 UTC
Message-ID
<45E7DC04.5010701@lu.unisi.ch>
In-Reply-To
<Pine.LNX.4.63.0703012240210.22628@wbgn013.biozentrum.uni-wuerzburg.de>
> please don't take my comments as insults or even strict rules. It is 
> purely for your consideration. (I say this because I haven't seen you so 
> often on this list, so you might not know that discussions about patches 
> are sometimes, erm, lively...)
I absolutely haven't taken any of these comments in the thread as insults (the only thing I found a little dubious, was some usage of uppercase), and I got a lot of constructive criticism that outweighed the "lively" tone.  And as a mistake on my part, I probably should have lurked a bit longer than I did.
>> +static void register_branch_pull (const char *name, const char *remote_name)
> 
> It is not yet remote_name, right? it is branch_name. You extract the 
> remote_name by finding the first slash.
Yeah, it's a remote_branch_name in fact.
> I'd use "char key[1024], value[1024]" instead, erroring out if one of the 
> buffers are too small. It's not like you have to be memory efficient, and 
> it is easier to read.
Ok.
>> +	remote_value[slash - remote_name] = 0;
> 
> You should check if slash == NULL and error out before using it.
remote_name is of the form "REMOTE/BRANCH", because it comes from dwim_ref's output after stripping "refs/remotes/" from the beginning.
> Yes, that is how I imagined it. The rest of your patch looks perfect to 
> me.
I will submit again with the requested changes.  I guess the body of this message is too long to become a "cover letter".
Paolo
Previous: Johannes SchindelinNext: Paolo Bonzini
Message 35 of 48 in “defaults for where to merge from”
  1. Paolo BonziniFeb 28, 2007
  2. Johannes SchindelinFeb 28, 2007
  3. Andy ParkinsFeb 28, 2007
  4. Paolo BonziniFeb 28, 2007
  5. Andy ParkinsFeb 28, 2007
  6. Julian PhillipsFeb 28, 2007
  7. Johannes SchindelinFeb 28, 2007
  8. Paolo BonziniFeb 28, 2007
  9. Johannes SchindelinFeb 28, 2007
  10. defaults for where to merge from (take 2)Paolo Bonzini, Mar 1, 2007
  11. Alex RiesenFeb 28, 2007
  12. Paolo BonziniFeb 28, 2007
  13. Alex RiesenMar 1, 2007
  14. Johannes SchindelinMar 1, 2007
  15. Alex RiesenMar 1, 2007
  16. Paolo BonziniMar 1, 2007
  17. Alex RiesenMar 1, 2007
  18. Junio C HamanoMar 1, 2007
  19. J. Bruce FieldsMar 2, 2007
  20. Paolo BonziniMar 1, 2007
  21. Alex RiesenMar 1, 2007
  22. Paolo BonziniMar 1, 2007
  23. Alex RiesenMar 1, 2007
  24. defaults for where to merge from (take 3)Paolo Bonzini, Mar 1, 2007
  25. Alex RiesenMar 1, 2007
  26. Paolo BonziniMar 1, 2007
  27. Junio C HamanoMar 1, 2007
  28. Alex RiesenMar 1, 2007
  29. Junio C HamanoMar 2, 2007
  30. Alex RiesenMar 2, 2007
  31. Junio C HamanoMar 2, 2007
  32. Alex RiesenMar 1, 2007
  33. Paolo BonziniMar 1, 2007
  34. Johannes SchindelinMar 1, 2007
  35. Paolo BonziniMar 2, 2007
  36. git-branch: register where to merge from, when branching off a remote branchPaolo Bonzini, Mar 2, 2007
  37. Junio C HamanoMar 2, 2007
  38. Junio C HamanoMar 2, 2007
  39. Jeff KingMar 2, 2007
  40. Paolo BonziniMar 2, 2007
  41. Jeff KingMar 2, 2007
  42. Paolo BonziniMar 2, 2007
  43. Johannes SchindelinMar 2, 2007
  44. Paolo BonziniMar 2, 2007
  45. Johannes SchindelinMar 2, 2007
  46. Johannes SchindelinMar 2, 2007
  47. Jakub NarebskiMar 2, 2007
  48. Peter BaumannFeb 28, 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.