[Libreoffice-commits] online.git: 3 commits - ios/Mobile ios/Mobile.xcodeproj net/FakeSocket.cpp

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Mar 20 13:23:14 UTC 2019


 ios/Mobile.xcodeproj/project.pbxproj |   82 +++++++++++++++++++++++++++++++++++
 ios/Mobile/Document.mm               |    5 ++
 ios/Mobile/DocumentViewController.mm |    6 ++
 net/FakeSocket.cpp                   |    2 
 4 files changed, 94 insertions(+), 1 deletion(-)

New commits:
commit eaa4a7838a913979eddd2304053b1697ad596586
Author:     Tor Lillqvist <tml at iki.fi>
AuthorDate: Wed Mar 20 15:12:31 2019 +0200
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Wed Mar 20 15:21:14 2019 +0200

    Add references to source files from svl/source/items for debugging goodness

diff --git a/ios/Mobile.xcodeproj/project.pbxproj b/ios/Mobile.xcodeproj/project.pbxproj
index 11c8bda23..07447d333 100644
--- a/ios/Mobile.xcodeproj/project.pbxproj
+++ b/ios/Mobile.xcodeproj/project.pbxproj
@@ -381,6 +381,39 @@
 		BE80E45C21B6CEF100859C97 /* TemplateSectionHeaderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TemplateSectionHeaderView.h; sourceTree = "<group>"; };
 		BE80E45D21B6CEF200859C97 /* TemplateSectionHeaderView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TemplateSectionHeaderView.m; sourceTree = "<group>"; };
 		BE80E46721B7066C00859C97 /* Templates */ = {isa = PBXFileReference; lastKnownFileType = folder; path = Templates; sourceTree = "<group>"; };
+		BE8C0372223FC4EB0048B7EA /* stringio.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = stringio.cxx; path = "../../ios-device/svl/source/items/stringio.cxx"; sourceTree = "<group>"; };
+		BE8C0373223FC4EB0048B7EA /* itemprop.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = itemprop.cxx; path = "../../ios-device/svl/source/items/itemprop.cxx"; sourceTree = "<group>"; };
+		BE8C0374223FC4EB0048B7EA /* itemset.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = itemset.cxx; path = "../../ios-device/svl/source/items/itemset.cxx"; sourceTree = "<group>"; };
+		BE8C0375223FC4EB0048B7EA /* macitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = macitem.cxx; path = "../../ios-device/svl/source/items/macitem.cxx"; sourceTree = "<group>"; };
+		BE8C0376223FC4EB0048B7EA /* poolcach.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = poolcach.cxx; path = "../../ios-device/svl/source/items/poolcach.cxx"; sourceTree = "<group>"; };
+		BE8C0377223FC4EB0048B7EA /* ilstitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = ilstitem.cxx; path = "../../ios-device/svl/source/items/ilstitem.cxx"; sourceTree = "<group>"; };
+		BE8C0378223FC4EC0048B7EA /* intitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = intitem.cxx; path = "../../ios-device/svl/source/items/intitem.cxx"; sourceTree = "<group>"; };
+		BE8C0379223FC4EC0048B7EA /* globalnameitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = globalnameitem.cxx; path = "../../ios-device/svl/source/items/globalnameitem.cxx"; sourceTree = "<group>"; };
+		BE8C037A223FC4EC0048B7EA /* imageitm.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = imageitm.cxx; path = "../../ios-device/svl/source/items/imageitm.cxx"; sourceTree = "<group>"; };
+		BE8C037B223FC4EC0048B7EA /* stylepool.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = stylepool.cxx; path = "../../ios-device/svl/source/items/stylepool.cxx"; sourceTree = "<group>"; };
+		BE8C037C223FC4EC0048B7EA /* custritm.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = custritm.cxx; path = "../../ios-device/svl/source/items/custritm.cxx"; sourceTree = "<group>"; };
+		BE8C037D223FC4EC0048B7EA /* stritem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = stritem.cxx; path = "../../ios-device/svl/source/items/stritem.cxx"; sourceTree = "<group>"; };
+		BE8C037E223FC4EC0048B7EA /* rectitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = rectitem.cxx; path = "../../ios-device/svl/source/items/rectitem.cxx"; sourceTree = "<group>"; };
+		BE8C037F223FC4EC0048B7EA /* style.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = style.cxx; path = "../../ios-device/svl/source/items/style.cxx"; sourceTree = "<group>"; };
+		BE8C0380223FC4EC0048B7EA /* grabbagitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = grabbagitem.cxx; path = "../../ios-device/svl/source/items/grabbagitem.cxx"; sourceTree = "<group>"; };
+		BE8C0381223FC4EC0048B7EA /* flagitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = flagitem.cxx; path = "../../ios-device/svl/source/items/flagitem.cxx"; sourceTree = "<group>"; };
+		BE8C0382223FC4EC0048B7EA /* poolio.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = poolio.cxx; path = "../../ios-device/svl/source/items/poolio.cxx"; sourceTree = "<group>"; };
+		BE8C0383223FC4EC0048B7EA /* srchitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = srchitem.cxx; path = "../../ios-device/svl/source/items/srchitem.cxx"; sourceTree = "<group>"; };
+		BE8C0384223FC4EC0048B7EA /* cintitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = cintitem.cxx; path = "../../ios-device/svl/source/items/cintitem.cxx"; sourceTree = "<group>"; };
+		BE8C0385223FC4EC0048B7EA /* IndexedStyleSheets.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = IndexedStyleSheets.cxx; path = "../../ios-device/svl/source/items/IndexedStyleSheets.cxx"; sourceTree = "<group>"; };
+		BE8C0386223FC4EC0048B7EA /* itemiter.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = itemiter.cxx; path = "../../ios-device/svl/source/items/itemiter.cxx"; sourceTree = "<group>"; };
+		BE8C0387223FC4EC0048B7EA /* poolitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = poolitem.cxx; path = "../../ios-device/svl/source/items/poolitem.cxx"; sourceTree = "<group>"; };
+		BE8C0388223FC4EC0048B7EA /* aeitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = aeitem.cxx; path = "../../ios-device/svl/source/items/aeitem.cxx"; sourceTree = "<group>"; };
+		BE8C0389223FC4ED0048B7EA /* whiter.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = whiter.cxx; path = "../../ios-device/svl/source/items/whiter.cxx"; sourceTree = "<group>"; };
+		BE8C038A223FC4ED0048B7EA /* slstitm.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = slstitm.cxx; path = "../../ios-device/svl/source/items/slstitm.cxx"; sourceTree = "<group>"; };
+		BE8C038B223FC4ED0048B7EA /* lckbitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = lckbitem.cxx; path = "../../ios-device/svl/source/items/lckbitem.cxx"; sourceTree = "<group>"; };
+		BE8C038C223FC4ED0048B7EA /* visitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = visitem.cxx; path = "../../ios-device/svl/source/items/visitem.cxx"; sourceTree = "<group>"; };
+		BE8C038D223FC4ED0048B7EA /* itempool.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = itempool.cxx; path = "../../ios-device/svl/source/items/itempool.cxx"; sourceTree = "<group>"; };
+		BE8C038E223FC4ED0048B7EA /* cenumitm.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = cenumitm.cxx; path = "../../ios-device/svl/source/items/cenumitm.cxx"; sourceTree = "<group>"; };
+		BE8C038F223FC4ED0048B7EA /* sitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = sitem.cxx; path = "../../ios-device/svl/source/items/sitem.cxx"; sourceTree = "<group>"; };
+		BE8C0390223FC4ED0048B7EA /* rngitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = rngitem.cxx; path = "../../ios-device/svl/source/items/rngitem.cxx"; sourceTree = "<group>"; };
+		BE8C0391223FC4ED0048B7EA /* ptitem.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = ptitem.cxx; path = "../../ios-device/svl/source/items/ptitem.cxx"; sourceTree = "<group>"; };
+		BE8C0392223FC4ED0048B7EA /* int64item.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = int64item.cxx; path = "../../ios-device/svl/source/items/int64item.cxx"; sourceTree = "<group>"; };
 		BE8D77272136762500AC58EA /* Mobile.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Mobile.app; sourceTree = BUILT_PRODUCTS_DIR; };
 		BE8D772A2136762500AC58EA /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
 		BE8D772B2136762500AC58EA /* AppDelegate.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = AppDelegate.mm; sourceTree = "<group>"; };
@@ -1033,6 +1066,7 @@
 				BEB6521A216F5D4600B8C09A /* sal */,
 				BE93D43C216D555C007A39F4 /* sfx2 */,
 				BE34D1892190712C00815297 /* sc */,
+				BE8C0370223FC4AC0048B7EA /* svl */,
 				BEB0E5DC21CA93950085A0CF /* svx */,
 				BE34D10C218B667400815297 /* sw */,
 				BEB6524B216FD09400B8C09A /* tools */,
@@ -1080,6 +1114,54 @@
 			name = cppuhelper;
 			sourceTree = "<group>";
 		};
+		BE8C0370223FC4AC0048B7EA /* svl */ = {
+			isa = PBXGroup;
+			children = (
+				BE8C0371223FC4BD0048B7EA /* items */,
+			);
+			name = svl;
+			sourceTree = "<group>";
+		};
+		BE8C0371223FC4BD0048B7EA /* items */ = {
+			isa = PBXGroup;
+			children = (
+				BE8C0388223FC4EC0048B7EA /* aeitem.cxx */,
+				BE8C038E223FC4ED0048B7EA /* cenumitm.cxx */,
+				BE8C0384223FC4EC0048B7EA /* cintitem.cxx */,
+				BE8C037C223FC4EC0048B7EA /* custritm.cxx */,
+				BE8C0381223FC4EC0048B7EA /* flagitem.cxx */,
+				BE8C0379223FC4EC0048B7EA /* globalnameitem.cxx */,
+				BE8C0380223FC4EC0048B7EA /* grabbagitem.cxx */,
+				BE8C0377223FC4EB0048B7EA /* ilstitem.cxx */,
+				BE8C037A223FC4EC0048B7EA /* imageitm.cxx */,
+				BE8C0385223FC4EC0048B7EA /* IndexedStyleSheets.cxx */,
+				BE8C0392223FC4ED0048B7EA /* int64item.cxx */,
+				BE8C0378223FC4EC0048B7EA /* intitem.cxx */,
+				BE8C0386223FC4EC0048B7EA /* itemiter.cxx */,
+				BE8C038D223FC4ED0048B7EA /* itempool.cxx */,
+				BE8C0373223FC4EB0048B7EA /* itemprop.cxx */,
+				BE8C0374223FC4EB0048B7EA /* itemset.cxx */,
+				BE8C038B223FC4ED0048B7EA /* lckbitem.cxx */,
+				BE8C0375223FC4EB0048B7EA /* macitem.cxx */,
+				BE8C0376223FC4EB0048B7EA /* poolcach.cxx */,
+				BE8C0382223FC4EC0048B7EA /* poolio.cxx */,
+				BE8C0387223FC4EC0048B7EA /* poolitem.cxx */,
+				BE8C0391223FC4ED0048B7EA /* ptitem.cxx */,
+				BE8C037E223FC4EC0048B7EA /* rectitem.cxx */,
+				BE8C0390223FC4ED0048B7EA /* rngitem.cxx */,
+				BE8C038F223FC4ED0048B7EA /* sitem.cxx */,
+				BE8C038A223FC4ED0048B7EA /* slstitm.cxx */,
+				BE8C0383223FC4EC0048B7EA /* srchitem.cxx */,
+				BE8C0372223FC4EB0048B7EA /* stringio.cxx */,
+				BE8C037D223FC4EC0048B7EA /* stritem.cxx */,
+				BE8C037F223FC4EC0048B7EA /* style.cxx */,
+				BE8C037B223FC4EC0048B7EA /* stylepool.cxx */,
+				BE8C038C223FC4ED0048B7EA /* visitem.cxx */,
+				BE8C0389223FC4ED0048B7EA /* whiter.cxx */,
+			);
+			name = items;
+			sourceTree = "<group>";
+		};
 		BE8D771E2136762500AC58EA = {
 			isa = PBXGroup;
 			children = (
commit 8dce31364219ed5a41a4f8f530ab658d4aff7778
Author:     Tor Lillqvist <tml at iki.fi>
AuthorDate: Wed Mar 20 15:08:42 2019 +0200
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Wed Mar 20 15:20:52 2019 +0200

    tdf#122543: Ignore duplicate calls to loadFromContents on same Document

diff --git a/ios/Mobile/Document.mm b/ios/Mobile/Document.mm
index 70d130d64..73ecd675d 100644
--- a/ios/Mobile/Document.mm
+++ b/ios/Mobile/Document.mm
@@ -49,6 +49,11 @@
 
 - (BOOL)loadFromContents:(id)contents ofType:(NSString *)typeName error:(NSError **)errorPtr {
 
+    // If this method is called a second time on the same Document object, just ignore it. This
+    // seems to happen occastionally when the device is awakened after sleep. See tdf#122543.
+    if (fakeClientFd >= 0)
+        return YES;
+
     fakeClientFd = fakeSocketSocket();
     NSString *uri = [[self fileURL] absoluteString];
 
diff --git a/ios/Mobile/DocumentViewController.mm b/ios/Mobile/DocumentViewController.mm
index 9a4503b41..1d70b2882 100644
--- a/ios/Mobile/DocumentViewController.mm
+++ b/ios/Mobile/DocumentViewController.mm
@@ -203,6 +203,12 @@
                                        }
                                        if (p[0].revents == POLLIN) {
                                            int n = fakeSocketAvailableDataLength(self.document->fakeClientFd);
+                                           // I don't want to check for n being -1 here, even if
+                                           // that will lead to a crash (std::length_error from the
+                                           // below std::vector constructor), as n being -1 is a
+                                           // sign of something being wrong elsewhere anyway, and I
+                                           // prefer to fix the root cause. Let's see how well this
+                                           // works out. See tdf#122543 for such a case.
                                            if (n == 0)
                                                return;
                                            std::vector<char> buf(n);
commit 08da0785462ea57e764dc9ee549efee79e18c988
Author:     Tor Lillqvist <tml at iki.fi>
AuthorDate: Wed Mar 20 13:17:57 2019 +0200
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Wed Mar 20 15:18:43 2019 +0200

    When FAKESOCKET_LOG_ALWAYS_STDERR, output also the thread id

diff --git a/net/FakeSocket.cpp b/net/FakeSocket.cpp
index a0e86f2a3..e230428aa 100644
--- a/net/FakeSocket.cpp
+++ b/net/FakeSocket.cpp
@@ -83,7 +83,7 @@ static std::string flush()
 {
     static bool alwaysStderr = std::getenv("FAKESOCKET_LOG_ALWAYS_STDERR") != nullptr;
     if (alwaysStderr)
-        std::cerr << loggingBuffer.str() << std::endl;
+        std::cerr << std::this_thread::get_id() << ":" << loggingBuffer.str() << std::endl;
     else if (loggingCallback != nullptr)
         loggingCallback(loggingBuffer.str());
     loggingBuffer.str("");


More information about the Libreoffice-commits mailing list