Merge pull request #2885 from gbrikis/master

core: Fix path for opening ffs endpoint ep0
This commit is contained in:
Daniel Mack 2016-03-23 19:48:26 +01:00
commit 1eb963a32d

View file

@ -1341,8 +1341,12 @@ static int socket_open_fds(Socket *s) {
break; break;
case SOCKET_USB_FUNCTION: case SOCKET_USB_FUNCTION:
{
_cleanup_free_ char *ep = NULL;
p->fd = usbffs_address_create(p->path); ep = path_make_absolute("ep0", p->path);
p->fd = usbffs_address_create(ep);
if (p->fd < 0) { if (p->fd < 0) {
r = p->fd; r = p->fd;
goto rollback; goto rollback;
@ -1357,7 +1361,7 @@ static int socket_open_fds(Socket *s) {
goto rollback; goto rollback;
break; break;
}
default: default:
assert_not_reached("Unknown port type"); assert_not_reached("Unknown port type");
} }