Staging
v0.8.1
Revision f2d0df7148a1b9ee69bd69a365ffcd1965872451 authored by Shawn Bohrer on 15 April 2008, 03:14:09 UTC, committed by Junio C Hamano on 15 April 2008, 06:14:58 UTC
When git clean is run from a subdirectory it should follow the normal
policy and only remove directories if they are passed in as a pathspec,
or -d is specified.

The fix is to send len which could be shorter than ent->len because we
have stripped the trailing '/' that read_directory adds. Additionaly
match_one() was modified to allow a name[] that is not NUL terminated.
This allows us to check if the name matched the pathspec exactly
instead of recursively.

Signed-off-by: Shawn Bohrer <shawn.bohrer@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent f669ac0
Raw File
decorate.h
#ifndef DECORATE_H
#define DECORATE_H

struct object_decoration {
	struct object *base;
	void *decoration;
};

struct decoration {
	const char *name;
	unsigned int size, nr;
	struct object_decoration *hash;
};

extern void *add_decoration(struct decoration *n, struct object *obj, void *decoration);
extern void *lookup_decoration(struct decoration *n, struct object *obj);

#endif
back to top