Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mode "c" doesn't seem to work as documented #32

Closed
sirotenko opened this issue Dec 27, 2016 · 3 comments
Closed

Mode "c" doesn't seem to work as documented #32

sirotenko opened this issue Dec 27, 2016 · 3 comments

Comments

@sirotenko
Copy link

The documentation say:

mode=c - Go to next image in the collection (set via the dirlist).
But if we look at the code here, we can see that it actually tries to read the contents of a specific folder:

elsif($mode eq "c") {
    opendir(DIR,$LM_HOME . "Images/users/$username/$collection") || die("Cannot read collections");
    my @all_images = readdir(DIR);
    closedir(DIR);

    my $c = 0;
    foreach my $i (@all_images) {
	if($i eq $image) {
	    goto next_section;
	}
	$c = $c+1;
    }
  next_section:
    if($c == scalar(@all_images)-1) {
	$c = 1;
    }
    $im_file = $all_images[$c+1];
    $im_dir = $folder;
}
@brianabrams
Copy link
Contributor

#33

@xavierpuigf
Copy link
Contributor

The pull request has been merged now. Thanks!

@Abhijit-2592
Copy link
Contributor

Abhijit-2592 commented Aug 30, 2017

Even after the merge the mode C doesn't seem to work properly. It shows problems with fetch_image.cgi.
It doesn't seem to read the "foo.txt" file that is created using populate_dirlist.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants