summaryrefslogtreecommitdiffstats
path: root/Source/CursesDialog/form/frm_driver.c
diff options
context:
space:
mode:
Diffstat (limited to 'Source/CursesDialog/form/frm_driver.c')
-rw-r--r--Source/CursesDialog/form/frm_driver.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/CursesDialog/form/frm_driver.c b/Source/CursesDialog/form/frm_driver.c
index cc07b65..3e1fbb1 100644
--- a/Source/CursesDialog/form/frm_driver.c
+++ b/Source/CursesDialog/form/frm_driver.c
@@ -3809,7 +3809,8 @@ int set_field_buffer(FIELD * field, int buffer, const char * value)
p[s-value] = *s;
if (s < (value+len))
{
- p[s-value] = *s++;
+ int off = s-value;
+ p[off] = *s++;
s = p + (s-value);
}
else