<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/object.c, branch v1.5.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://www.git.shady.money/git/atom?h=v1.5.2</id>
<link rel='self' href='https://www.git.shady.money/git/atom?h=v1.5.2'/>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/'/>
<updated>2007-04-24T07:08:49Z</updated>
<entry>
<title>add add_object_array_with_mode</title>
<updated>2007-04-24T07:08:49Z</updated>
<author>
<name>Martin Koegler</name>
<email>mkoegler@auto.tuwien.ac.at</email>
</author>
<published>2007-04-22T16:43:58Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=e5709a4a6809e45bf59b851debf24a813e1c6b58'/>
<id>urn:sha1:e5709a4a6809e45bf59b851debf24a813e1c6b58</id>
<content type='text'>
Each object in struct object_array is extended with the mode.
If not specified, S_IFINVALID is used. An object with an mode value
can be added with add_object_array_with_mode.

Signed-off-by: Martin Koegler &lt;mkoegler@auto.tuwien.ac.at&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Clean up object creation to use more common code</title>
<updated>2007-04-17T06:36:16Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2007-04-17T05:11:43Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=100c5f3b0b27ec6617de1a785c4ff481e92636c1'/>
<id>urn:sha1:100c5f3b0b27ec6617de1a785c4ff481e92636c1</id>
<content type='text'>
This replaces the fairly odd "created_object()" function that did _most_
of the object setup with a more complete "create_object()" function that
also has a more natural calling convention.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Use proper object allocators for unknown object nodes too</title>
<updated>2007-04-17T06:36:11Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2007-04-17T05:10:19Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=2c1cbec1e2f0bd7b15fe5e921d287babfd91c7d3'/>
<id>urn:sha1:2c1cbec1e2f0bd7b15fe5e921d287babfd91c7d3</id>
<content type='text'>
We used to use a different allocator scheme for when we didn't know the
object type.  That meant that objects that were created without any
up-front knowledge of the type would not go through the same allocation
paths as normal object allocations, and would miss out on the statistics.

But perhaps more importantly than the statistics (that are useful when
looking at memory usage but not much else), if we want to make the
object hash tables use a denser object pointer representation, we need
to make sure that they all go through the same blocking allocator.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Don't ever return corrupt objects from "parse_object()"</title>
<updated>2007-03-21T05:17:17Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2007-03-20T17:05:20Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=acdeec62cb644e48436bbe931e69b3d4842344cb'/>
<id>urn:sha1:acdeec62cb644e48436bbe931e69b3d4842344cb</id>
<content type='text'>
Looking at the SHA1 validation code due to the corruption that Alexander
Litvinov is seeing under Cygwin, I notice that one of the most central
places where we read objects, we actually do end up verifying the SHA1 of
the result, but then we happily parse it anyway.

And using "printf" to write the error message means that it not only can
get lost, but will actually mess up stdout, and cause other strange and
hard-to-debug failures downstream.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>get rid of lookup_object_type()</title>
<updated>2007-02-27T09:34:21Z</updated>
<author>
<name>Nicolas Pitre</name>
<email>nico@cam.org</email>
</author>
<published>2007-02-26T19:56:00Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=0ab179504a17907c395a4009f7c23d2f71bba1d3'/>
<id>urn:sha1:0ab179504a17907c395a4009f7c23d2f71bba1d3</id>
<content type='text'>
This function is called only once in the whole source tree.  Let's move
its code inline instead, which is also in the spirit of removing as much
object type char arrays as possible (not that this patch does anything for
that but at least it is now a local matter).

Signed-off-by: Nicolas Pitre &lt;nico@cam.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>convert object type handling from a string to a number</title>
<updated>2007-02-27T09:34:21Z</updated>
<author>
<name>Nicolas Pitre</name>
<email>nico@cam.org</email>
</author>
<published>2007-02-26T19:55:59Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=21666f1aae4e890d8f50924f9e80763b27e6a45d'/>
<id>urn:sha1:21666f1aae4e890d8f50924f9e80763b27e6a45d</id>
<content type='text'>
We currently have two parallel notation for dealing with object types
in the code: a string and a numerical value.  One of them is obviously
redundent, and the most used one requires more stack space and a bunch
of strcmp() all over the place.

This is an initial step for the removal of the version using a char array
found in object reading code paths.  The patch is unfortunately large but
there is no sane way to split it in smaller parts without breaking the
system.

Signed-off-by: Nicolas Pitre &lt;nico@cam.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>formalize typename(), and add its reverse type_from_string()</title>
<updated>2007-02-27T09:34:21Z</updated>
<author>
<name>Nicolas Pitre</name>
<email>nico@cam.org</email>
</author>
<published>2007-02-26T19:55:58Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=df8436622fb553f468180b61032fe34bd6712752'/>
<id>urn:sha1:df8436622fb553f468180b61032fe34bd6712752</id>
<content type='text'>
Sometime typename() is used, sometimes type_names[] is accessed directly.
Let's enforce typename() all the time which allows for validating the
type.

Also let's add a function to go from a name to a type and use it instead
of manual memcpy() when appropriate.

Signed-off-by: Nicolas Pitre &lt;nico@cam.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Add git-for-each-ref: helper for language bindings</title>
<updated>2006-09-16T17:22:02Z</updated>
<author>
<name>Junio C Hamano</name>
<email>junkio@cox.net</email>
</author>
<published>2006-09-15T20:30:02Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=9f613ddd21cbd05bfc139d9b1551b5780aa171f6'/>
<id>urn:sha1:9f613ddd21cbd05bfc139d9b1551b5780aa171f6</id>
<content type='text'>
This adds a new command, git-for-each-ref.  You can have it iterate
over refs and have it output various aspects of the objects they
refer to.

Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Use xcalloc instead of calloc</title>
<updated>2006-08-28T03:49:43Z</updated>
<author>
<name>Jonas Fonseca</name>
<email>fonseca@diku.dk</email>
</author>
<published>2006-08-28T00:26:07Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=b3c952f8386cebe12fc95227866683bb1cec99a9'/>
<id>urn:sha1:b3c952f8386cebe12fc95227866683bb1cec99a9</id>
<content type='text'>
Signed-off-by: Jonas Fonseca &lt;fonseca@diku.dk&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
<entry>
<title>Convert memcpy(a,b,20) to hashcpy(a,b).</title>
<updated>2006-08-23T20:53:10Z</updated>
<author>
<name>Shawn Pearce</name>
<email>spearce@spearce.org</email>
</author>
<published>2006-08-23T06:49:00Z</published>
<link rel='alternate' type='text/html' href='https://www.git.shady.money/git/commit/?id=e702496e434a160f798447b95b9cea3cd138c140'/>
<id>urn:sha1:e702496e434a160f798447b95b9cea3cd138c140</id>
<content type='text'>
This abstracts away the size of the hash values when copying them
from memory location to memory location, much as the introduction
of hashcmp abstracted away hash value comparsion.

A few call sites were using char* rather than unsigned char* so
I added the cast rather than open hashcpy to be void*.  This is a
reasonable tradeoff as most call sites already use unsigned char*
and the existing hashcmp is also declared to be unsigned char*.

[jc: Splitted the patch to "master" part, to be followed by a
 patch for merge-recursive.c which is not in "master" yet.

 Fixed the cast in the latter hunk to combine-diff.c which was
 wrong in the original.

 Also converted ones left-over in combine-diff.c, diff-lib.c and
 upload-pack.c ]

Signed-off-by: Shawn O. Pearce &lt;spearce@spearce.org&gt;
Signed-off-by: Junio C Hamano &lt;junkio@cox.net&gt;
</content>
</entry>
</feed>
