Imported Upstream version 3.3.2
[debian/amanda] / device-src / activate-devpay.c
index 196834d6cf03b1f20e32b8886ea7bd24bfa58faf..db3ec7733b6e6a45706c77efdbd123e77b92c089 100644 (file)
 #include "base64.h"
 #include "s3.h"
 
-#ifndef WANT_DEVPAY
-# error activate_devpay only works if devpay is enabled.
-#endif
-
 #define MAX_RESPONSE_SIZE (1024*1024)
 
 typedef struct {
@@ -147,7 +143,7 @@ static void parser_got_text(GMarkupParseContext * context,
             /* Do nothing; wait for the message. */
         }
     } else if (g_strrstr(current_tag, "Message")) {
-        g_set_error(error, G_MARKUP_ERROR, -1, "%.*s", text_len, text);
+        g_set_error(error, G_MARKUP_ERROR, -1, "%.*s", (int)text_len, text);
     }
 }               
 
@@ -198,9 +194,9 @@ static void do_output(Credentials * rare) {
         exit(EXIT_FAILURE);
     }
 
-    g_printf("device_property \"S3_USER_TOKEN\" \"%s\"\n"
-             "device_property \"S3_ACCESS_KEY\" \"%s\"\n"
-             "device_property \"S3_SECRET_KEY\" \"%s\"\n",
+    g_printf("device-property \"S3_USER_TOKEN\" \"%s\"\n"
+             "device-property \"S3_ACCESS_KEY\" \"%s\"\n"
+             "device-property \"S3_SECRET_KEY\" \"%s\"\n",
              rare->user_token->str, rare->access_key->str,
              rare->secret_key->str);
 }