Skip to content

Commit 092da29

Browse files
committed
main: put more const modifiers
1 parent f1a0361 commit 092da29

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

main/promise.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ int getLastPromise (void)
197197
return promise_count - 1;
198198
}
199199

200-
static unsigned char* fill_or_skip (unsigned char *input, const unsigned char *const input_end, bool filling)
200+
static unsigned char* fill_or_skip (unsigned char *input, const unsigned char *const input_end, const bool filling)
201201
{
202202
if ( !(input < input_end))
203203
return NULL;
@@ -221,9 +221,9 @@ static unsigned char* fill_or_skip (unsigned char *input, const unsigned char *c
221221
}
222222
}
223223

224-
static void line_filler (unsigned char *input, size_t size,
225-
unsigned long startLine, long startCharOffset,
226-
unsigned long endLine, long endCharOffset,
224+
static void line_filler (unsigned char *input, size_t const size,
225+
unsigned long const startLine, long const startCharOffset,
226+
unsigned long const endLine, long const endCharOffset,
227227
void *data)
228228
{
229229
const ulongArray *lines = data;
@@ -233,7 +233,7 @@ static void line_filler (unsigned char *input, size_t size,
233233

234234
for (i = 0; i < count; i++)
235235
{
236-
unsigned long line = ulongArrayItem (lines, i);
236+
const unsigned long line = ulongArrayItem (lines, i);
237237
if (line >= startLine)
238238
{
239239
if (line > endLine)
@@ -247,7 +247,7 @@ static void line_filler (unsigned char *input, size_t size,
247247

248248
for (; i < count; i++)
249249
{
250-
unsigned long line = ulongArrayItem (lines, i);
250+
const unsigned long line = ulongArrayItem (lines, i);
251251
if (line > endLine)
252252
break;
253253
}
@@ -257,7 +257,7 @@ static void line_filler (unsigned char *input, size_t size,
257257
const unsigned char *const input_end = input + size;
258258
for (i = start_index; i < end_index; i++)
259259
{
260-
unsigned long line = ulongArrayItem (lines, i);
260+
const unsigned long line = ulongArrayItem (lines, i);
261261

262262
while (1)
263263
{

0 commit comments

Comments
 (0)