1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-01-31 11:23:40 +00:00

(trunk daemon) #2899: "watch.c reports matches for every file" -- fixed in trunk for 1.90

This commit is contained in:
Charles Kerr 2010-02-12 12:50:36 +00:00
parent a694ac185c
commit 6958386ecd

View file

@ -99,8 +99,11 @@ watchdir_update_impl( dtr_watchdir * w )
int len = read( fd, buf, sizeof( buf ) );
while (i < len) {
struct inotify_event * event = (struct inotify_event *) &buf[i];
tr_inf( "Found new .torrent file \"%s\" in watchdir \"%s\"", event->name, w->dir );
w->callback( w->session, w->dir, event->name );
if( strstr( event->name, ".torrent" ) != NULL )
{
tr_inf( "Found new .torrent file \"%s\" in watchdir \"%s\"", event->name, w->dir );
w->callback( w->session, w->dir, event->name );
}
i += EVENT_SIZE + event->len;
}
}