Detect full disk during data migration on Windows (hopefully)

This commit is contained in:
Dan Stillman 2017-06-30 16:59:33 -04:00
parent 010bf3b8f9
commit 536d7254fb

View File

@ -528,12 +528,12 @@ Zotero.File = new function(){
if (!(e instanceof OS.File.Error)) { if (!(e instanceof OS.File.Error)) {
return; return;
} }
Components.classes["@mozilla.org/net/osfileconstantsservice;1"]
if (!Zotero.isWin) { .getService(Components.interfaces.nsIOSFileConstantsService)
switch (e.unixErrno) { .init();
case OS.Constants.libc.ENOSPC: if ((e.unixErrno !== undefined && e.unixErrno == OS.Constants.libc.ENOSPC)
throw e; || (e.winLastError !== undefined && e.winLastError == OS.Constants.libc.ENOSPC)) {
} throw e;
} }
} }