Skip to content

Commit 87769de

Browse files
committed
ps2link/ps2link_request_opendir: move loop0 variable definition
1 parent 211df54 commit 87769de

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/ps2link.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -418,7 +418,7 @@
418418

419419
}
420420

421-
int ps2link_request_opendir(void *packet) { int loop0 = 0;
421+
int ps2link_request_opendir(void *packet) {
422422
struct { unsigned int command; unsigned short length; int flags; char pathname[256]; } PACKED *request = packet;
423423
int result = -1;
424424
struct stat stats;
@@ -429,7 +429,7 @@
429429
if((stat(request->pathname, &stats) == 0) && (S_ISDIR(stats.st_mode)))
430430
{
431431
// Allocate an available directory descriptor.
432-
for (loop0=0; loop0<10; loop0++) { if (ps2link_dd[loop0].dir == NULL) { result = loop0; break; } }
432+
for (int loop0=0; loop0<10; loop0++) { if (ps2link_dd[loop0].dir == NULL) { result = loop0; break; } }
433433

434434
// Perform the request.
435435
if (result != -1)

0 commit comments

Comments
 (0)