diff options
author | William Wilgus <me.theuser@yahoo.com> | 2018-12-10 12:04:55 -0600 |
---|---|---|
committer | William Wilgus <me.theuser@yahoo.com> | 2018-12-10 12:04:55 -0600 |
commit | ce0b31d87db3c4c1c1bfb535c50770d33e9c4aaf (patch) | |
tree | 8308a42cc60ace436664bb05cac486856d6f2f69 /apps/shortcuts.c | |
parent | 4055f90f083736f966a5424ec18caea917c04d8d (diff) |
Shortcuts, Fix FS#13151 Deleting shortcut removes name, icon, talkclip
FS#13151 - Deleting item from shortcut menu corrupts the menu's display
The function that writes shortcut.txt didn't write existing
name, icon or talkclip items
Change-Id: I4418700c82f91522b2dd8a975548d7bd91f150d3
Now: writes all three supplying default values if the items don't exist
Diffstat (limited to 'apps/shortcuts.c')
-rw-r--r-- | apps/shortcuts.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/shortcuts.c b/apps/shortcuts.c index 9abd82af2f..a0b6327e54 100644 --- a/apps/shortcuts.c +++ b/apps/shortcuts.c @@ -235,6 +235,12 @@ static void shortcuts_ata_idle_callback(void) write(fd, sc->u.setting->cfg_name, strlen(sc->u.setting->cfg_name)); else write(fd, sc->u.path, strlen(sc->u.path)); + + /* write name:, icon:, talkclip: */ + len = snprintf(buf, MAX_PATH, "\nname: %s\nicon: %d\ntalkclip: ", + sc->name, sc->icon); + write(fd, buf, len); + write(fd, sc->talk_clip, strlen(sc->talk_clip)); write(fd, "\n\n", 2); } close(fd); |