#ifndef INCLUDE_revwalk_h__
#define INCLUDE_revwalk_h__

#include "git/common.h"
#include "git/revwalk.h"

struct git_revpool {
	git_odb *db;

	git_commit_list iterator;
	git_commit *(*next_commit)(git_commit_list *);

	git_commit_list roots;
	git_revpool_table *commits;

	unsigned walking:1;
	unsigned char sorting;
};

void gitrp__prepare_walk(git_revpool *pool);
int gitrp__enroot(git_revpool *pool, git_commit *commit);

#endif /* INCLUDE_revwalk_h__ */

#ifndef INCLUDE_revwalk_h__
#define INCLUDE_revwalk_h__

#include "git/common.h"
#include "git/revwalk.h"

struct git_revpool {
	git_odb *db;

	git_commit_list iterator;
	git_commit *(*next_commit)(git_commit_list *);

	git_commit_list roots;
	git_revpool_table *commits;

	unsigned walking:1;
	unsigned int sorting;
};

void gitrp__prepare_walk(git_revpool *pool);
int gitrp__enroot(git_revpool *pool, git_commit *commit);

#endif /* INCLUDE_revwalk_h__ */

Fix an "conversion, loss of data" compiler warning
msvc: Fix an "conversion, loss of data" compiler warning

In particular, the compiler issues the following warning:

    src/revwalk.c(61) : warning C4244: '=' : conversion from \
        'unsigned int' to 'unsigned char', possible loss of data

In order to suppress the warning, we change the type of the
sorting "enum" field of the git_revpool structure to be consistent
with the sort_mode parameter of the gitrp_sorting() function.

Note that if the size of the git_revpool structure is an issue,
then we could change the type of the sort_mode parameter instead.

Signed-off-by: Ramsay Jones <3e74413778ce9c8bebbbaedfd56741f6850faeaf@ramsay1.demon.co.uk>
Signed-off-by: Andreas Ericsson <1eabdaf488b3a3682bbca94c5f468f065cdfaf13@op5.se>
