[fix] changed some output strings to increase readability
This commit is contained in:
@@ -72,7 +72,7 @@ get (char *url, const gchar *output_file_path)
|
||||
} else if (SOUP_STATUS_IS_SUCCESSFUL (msg->status_code)) {
|
||||
//if there is no file name and path the page will not get saved
|
||||
if (output_file_path == NULL) {
|
||||
g_print ("Got a file offered form a other peer. Will not save anything.\n");
|
||||
//g_print ("%s: Got a file offered form a other peer. Will not save anything.\n", name);
|
||||
}
|
||||
else {
|
||||
output_file = fopen (output_file_path, "w");
|
||||
@@ -103,7 +103,7 @@ int do_client_notify (char * url)
|
||||
|
||||
int do_downloading (char * url, char * file_name)
|
||||
{
|
||||
g_print("Downloading url %s\n", url);
|
||||
g_print("Downloading %s to %s (Does not yet save)\n", url, g_uri_escape_string(file_name, NULL, TRUE));
|
||||
//get (g_strdup(url),"./test_download");
|
||||
//get ("http://juliansparber.com/index.html", "./test_download");
|
||||
return 0;
|
||||
|
||||
@@ -230,9 +230,9 @@ do_get_response_json (SoupServer *server, SoupMessage *msg, const char *path)
|
||||
soup_message_set_status (msg, SOUP_STATUS_OK);
|
||||
}
|
||||
static void handle_incoming_file(const char * hash, const char * name, const char * size, const char * origin) {
|
||||
g_print("Got a new file form %s with size:%s with title: %s\n", origin, size, name);
|
||||
//If the user accepts the file
|
||||
do_downloading(g_strdup_printf("http://%s:%d/transfer/%s", origin, port, hash), name);
|
||||
g_print("Got a new file form %s with size:%s with title: %s\n", origin, size, name);
|
||||
}
|
||||
|
||||
static void
|
||||
|
||||
Reference in New Issue
Block a user