Commit fb190bbbd06952b369b4fb6c06fa827802671332

Linquize 2013-11-12T19:44:13

Fix warnings

diff --git a/examples/blame.c b/examples/blame.c
index 95bce6b..06310d5 100644
--- a/examples/blame.c
+++ b/examples/blame.c
@@ -114,7 +114,7 @@ int main(int argc, char *argv[])
 					rawdata+i);
 		}
 
-		i = eol - rawdata + 1;
+		i = (int)(eol - rawdata + 1);
 		line++;
 	}
 
diff --git a/src/netops.c b/src/netops.c
index d7f17b1..592e464 100644
--- a/src/netops.c
+++ b/src/netops.c
@@ -662,7 +662,7 @@ void gitno_connection_data_free_ptrs(gitno_connection_data *d)
 static char* unescape(char *str)
 {
 	int x, y;
-	int len = strlen(str);
+	size_t len = strlen(str);
 
 	for (x=y=0; str[y]; ++x, ++y) {
 		if ((str[x] = str[y]) == '%') {
diff --git a/src/pack-objects.c b/src/pack-objects.c
index 9967cab..2d62507 100644
--- a/src/pack-objects.c
+++ b/src/pack-objects.c
@@ -272,7 +272,7 @@ static int write_object(git_buf *buf, git_packbuilder *pb, git_pobject *po)
 	git_buf zbuf = GIT_BUF_INIT;
 	git_otype type;
 	unsigned char hdr[10];
-	unsigned int hdr_len;
+	size_t hdr_len;
 	unsigned long size;
 	void *data;
 
diff --git a/src/push.c b/src/push.c
index 4f442c6..5ad15e3 100644
--- a/src/push.c
+++ b/src/push.c
@@ -618,7 +618,7 @@ on_error:
 
 static int filter_refs(git_remote *remote)
 {
-	const git_remote_head **heads;
+	git_remote_head **heads;
 	size_t heads_len, i;
 
 	git_vector_clear(&remote->refs);