diff options
Diffstat (limited to 'apps/plugins/alpine_cdc.c')
-rw-r--r-- | apps/plugins/alpine_cdc.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/plugins/alpine_cdc.c b/apps/plugins/alpine_cdc.c index 73bc49ff00..9357b2e5ab 100644 --- a/apps/plugins/alpine_cdc.c +++ b/apps/plugins/alpine_cdc.c | |||
@@ -1141,6 +1141,7 @@ int main(const void* parameter) | |||
1141 | #ifdef DEBUG | 1141 | #ifdef DEBUG |
1142 | int button; | 1142 | int button; |
1143 | #endif | 1143 | #endif |
1144 | size_t buf_size; | ||
1144 | ssize_t stacksize; | 1145 | ssize_t stacksize; |
1145 | void* stack; | 1146 | void* stack; |
1146 | 1147 | ||
@@ -1155,7 +1156,8 @@ int main(const void* parameter) | |||
1155 | #endif | 1156 | #endif |
1156 | 1157 | ||
1157 | /* init the worker thread */ | 1158 | /* init the worker thread */ |
1158 | stack = rb->plugin_get_buffer((size_t *)&stacksize); /* use the rest as stack */ | 1159 | stack = rb->plugin_get_buffer(&buf_size); /* use the rest as stack */ |
1160 | stacksize = buf_size; | ||
1159 | stack = (void*)(((unsigned int)stack + 100) & ~3); /* a bit away, 32 bit align */ | 1161 | stack = (void*)(((unsigned int)stack + 100) & ~3); /* a bit away, 32 bit align */ |
1160 | stacksize = (stacksize - 100) & ~3; | 1162 | stacksize = (stacksize - 100) & ~3; |
1161 | if (stacksize < DEFAULT_STACK_SIZE) | 1163 | if (stacksize < DEFAULT_STACK_SIZE) |