#include <stdarg.h>
#include <stdlib.h>
#include <errno.h>
+#include <glib.h>
#include <gnome-keyring.h>
/*
static int credential_read(struct credential *c)
{
char buf[1024];
- ssize_t line_len = 0;
+ size_t line_len;
char *key = buf;
char *value;
{
line_len = strlen(buf);
- if (buf[line_len-1]=='\n')
+ if (line_len && buf[line_len-1] == '\n')
buf[--line_len]='\0';
if (!line_len)
exit(EXIT_FAILURE);
}
+ g_set_application_name("Git Credential Helper");
+
/* lookup operation callback */
while (try_op->name && strcmp(argv[1], try_op->name))
try_op++;