[riot-notifications] [RIOT-OS/RIOT] doc/memos: RDM Runtime Configuration Architecture (#10622)

Leandro Lanzieri notifications at github.com
Mon Jan 14 16:09:24 CET 2019


leandrolanzieri commented on this pull request.



> +            printf("[registr_store_dummy]: Checking slot with name %s\n",dummy_store[i].name);
+            if (!strcmp(name, dummy_store[i].name)) {
+                printf("[registry_store_dummy] Saved in slot: %d\n", i);
+                strcpy(dummy_store[i].val, value);
+                return 0;
+            }
+        }
+        else {
+            if (free_slot == -1) {
+                printf("[registry_store_dummy]: Free slot in: %d\n", i);
+                free_slot = i;
+            }
+        }
+    }
+
+    if (free_slot == -1) {

This assumes that at startup the array is not initialized, that's why the first free slot is searched. How do you suggest to do it instead? 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/10622#discussion_r247527518
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190114/800d4dd2/attachment.html>


More information about the notifications mailing list