Przeglądaj źródła

Merge pull request #274 from NOVBobLee/pr_patch2

Remove the redundant code
Jim Huang 6 miesięcy temu
rodzic
commit
3203aa3ce5
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      examples/hello-sysfs.c

+ 1 - 1
examples/hello-sysfs.c

@@ -23,7 +23,7 @@ static ssize_t myvariable_store(struct kobject *kobj,
                                 struct kobj_attribute *attr, char *buf,
                                 size_t count)
 {
-    sscanf(buf, "%du", &myvariable);
+    sscanf(buf, "%d", &myvariable);
     return count;
 }