Use absolute path for inputs

This commit is contained in:
Iwan Timmer
2014-01-16 11:37:08 +01:00
parent 8205e18cf7
commit 69761e84cd

View File

@@ -49,12 +49,15 @@ public class Limelight implements NvConnectionListener {
if (inputs.isEmpty()) {
File input = new File("/dev/input");
inputs.addAll(Arrays.asList(input.list(new FilenameFilter() {
String[] events = input.list(new FilenameFilter() {
@Override
public boolean accept(File dir, String name) {
return name.startsWith("event");
}
})));
});
for (String event:events)
inputs.add(new File(input, event).getAbsolutePath());
}
for (String input:inputs) {