[Libreoffice-commits] core.git: sal/osl
Stephan Bergmann
sbergman at redhat.com
Wed Mar 28 08:20:11 UTC 2018
sal/osl/unx/file.cxx | 14 --------------
1 file changed, 14 deletions(-)
New commits:
commit f86fb57510ebb5563c51859935e45f70aba06359
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Wed Mar 28 08:42:37 2018 +0200
Revert "Temporary hack for iOS: open files read-only if read-write open fails"
This reverts commit bdbb0d1cc13a11c8c857ee2d387771a8c2622488. Assumed to no
longer be necessary after 9906c6d2a55b6f8a27903f0ef08aa8949d7a71c2
"rhbz#1559633: Treat EPERM same as EACCES when opening files".
Conflicts:
sal/osl/unx/file.cxx
Change-Id: I9f7ef544da3fec00810cd1d55bb52bf0470d1054
Reviewed-on: https://gerrit.libreoffice.org/51979
Reviewed-by: Tor Lillqvist <tml at collabora.com>
Tested-by: Jenkins <ci at libreoffice.org>
diff --git a/sal/osl/unx/file.cxx b/sal/osl/unx/file.cxx
index 5d0af4d774be..27075be25e05 100644
--- a/sal/osl/unx/file.cxx
+++ b/sal/osl/unx/file.cxx
@@ -940,20 +940,6 @@ oslFileError openFilePath(const char *cpFilePath, oslFileHandle* pHandle, sal_uI
/* open the file */
int fd = open_c( cpFilePath, flags, mode );
-
-#ifdef IOS
- /* Horrible hack: If opening for RDWR and getting EPERM, just try
- * again for RDONLY. Quicker this way than to figure out why
- * we get that oh so useful General Error when trying to open a
- * read-only document.
- */
- if (fd == -1 && (flags & O_RDWR) && errno == EPERM)
- {
- int rdonly_flags = (flags & ~O_ACCMODE) | O_RDONLY;
- fd = open_c( cpFilePath, rdonly_flags, mode );
- }
-#endif
-
if (fd == -1)
{
int saved_errno = errno;
More information about the Libreoffice-commits
mailing list