provides developper files
[src/app-framework-binder.git] / plugins / samples / SamplePost.c
index cfb0c59..1d3069e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2015 "IoT.bzh"
+ * Copyright (C) 2015, 2016 "IoT.bzh"
  * Author "Fulup Ar Foll"
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
@@ -20,7 +20,7 @@
 #include <string.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 
 // Sample Generic Ping Debug API
@@ -49,7 +49,7 @@ static void Uploads (struct afb_req request, const char *destination)
 {
    struct afb_arg a = afb_req_get(request, "file");
    if (a.value == NULL || *a.value == 0)
-     afb_req_fail_f(request, "failed", "no file selected");
+     afb_req_fail(request, "failed", "no file selected");
    else
      afb_req_success_f(request, NULL, "uploaded file %s of path %s for destination %s", a.value, a.path, destination);
 }