mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-11-05 19:51:45 +00:00
Fix fsdev_set_default_device bug
This commit is contained in:
parent
ae78ee22da
commit
25db9fcc4a
1 changed files with 5 additions and 6 deletions
|
@ -124,10 +124,6 @@ int fsdev_mount_device(const char *name, unsigned int id) {
|
|||
}
|
||||
|
||||
int fsdev_set_default_device(const char *name) {
|
||||
#if FF_VOLUMES < 2
|
||||
return 0;
|
||||
#else
|
||||
|
||||
int ret;
|
||||
char drname[40];
|
||||
int devid = FindDevice(name);
|
||||
|
@ -137,17 +133,20 @@ int fsdev_set_default_device(const char *name) {
|
|||
return -1;
|
||||
}
|
||||
|
||||
#if FF_VOLUMES < 2
|
||||
ret = 0;
|
||||
#else
|
||||
|
||||
strcpy(drname, name);
|
||||
strcat(drname, ":");
|
||||
|
||||
ret = fsdev_convert_rc(NULL, f_chdrive(drname));
|
||||
|
||||
#endif
|
||||
if (ret == 0) {
|
||||
setDefaultDevice(devid);
|
||||
}
|
||||
|
||||
return ret;
|
||||
#endif
|
||||
}
|
||||
|
||||
int fsdev_unmount_device(const char *name) {
|
||||
|
|
Loading…
Reference in a new issue