Skip to content

Commit cdbb640

Browse files
committed
add pattern for lfs.dir on WIN32
1 parent 50919ed commit cdbb640

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -556,7 +556,7 @@ static int dir_iter_factory (lua_State *L) {
556556
if (strlen(path) > MAX_PATH-2)
557557
luaL_error (L, "path too long: %s", path);
558558
else
559-
sprintf (d->pattern, "%s/*", path);
559+
sprintf (d->pattern, "%s/%s", path, luaL_optstring(L, 2, "*"));
560560
#else
561561
d->dir = opendir (path);
562562
if (d->dir == NULL)

0 commit comments

Comments
 (0)