No description
Find a file
Miklos Vajna 4e1ed7205d net: avoid UB in WebSocketHandler::readPayload()
Seen when closing a Writer document.

/home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/bits/stl_vector.h:798:9: runtime error: reference binding to null pointer of type 'char'
    #0 0x6ff633 in std::vector<char, std::allocator<char> >::operator[](unsigned long) /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/bits/stl_vector.h:798:2
    #1 0x770d0c in WebSocketHandler::readPayload(unsigned char*, unsigned long, unsigned char*, std::vector<char, std::allocator<char> >&) /home/vmiklos/lode/dev/online/./net/WebSocketHandler.hpp:611:29
    #2 0x759324 in WebSocketHandler::handleTCPStream(std::shared_ptr<StreamSocket> const&) /home/vmiklos/lode/dev/online/./net/WebSocketHandler.hpp:251:13
    #3 0x6f820d in WebSocketHandler::handleIncomingMessage(SocketDisposition&) /home/vmiklos/lode/dev/online/./net/WebSocketHandler.hpp:419:20
    #4 0xb2da64 in ClientSession::handleIncomingMessage(SocketDisposition&) /home/vmiklos/lode/dev/online/wsd/ClientSession.cpp:74:14
    #5 0xa70a61 in StreamSocket::handlePoll(SocketDisposition&, std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l> > >, int) /home/vmiklos/lode/dev/online/./net/Socket.hpp:1037:29
    #6 0x6ec83d in SocketPoll::poll(int) /home/vmiklos/lode/dev/online/./net/Socket.hpp:570:34
    #7 0x830019 in DocumentBroker::pollThread() /home/vmiklos/lode/dev/online/wsd/DocumentBroker.cpp:286:16
    #8 0x8fdb38 in DocumentBroker::DocumentBrokerPoll::pollingThread() /home/vmiklos/lode/dev/online/wsd/DocumentBroker.cpp:165:20
    #9 0xe00e75 in SocketPoll::pollingThreadEntry() /home/vmiklos/lode/dev/online/net/Socket.cpp:184:9
    #10 0xe49cfd in void std::__invoke_impl<void, void (SocketPoll::*)(), SocketPoll*>(std::__invoke_memfun_deref, void (SocketPoll::*&&)(), SocketPoll*&&) /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/bits/invoke.h:73:14
    #11 0xe4980a in std::__invoke_result<void (SocketPoll::*)(), SocketPoll*>::type std::__invoke<void (SocketPoll::*)(), SocketPoll*>(void (SocketPoll::*&&)(), SocketPoll*&&) /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/bits/invoke.h:95:14
    #12 0xe496bd in decltype(std::__invoke(_S_declval<0ul>(), _S_declval<1ul>())) std:🧵:_Invoker<std::tuple<void (SocketPoll::*)(), SocketPoll*> >::_M_invoke<0ul, 1ul>(std::_Index_tuple<0ul, 1ul>) /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/thread:234:13
    #13 0xe494c7 in std:🧵:_Invoker<std::tuple<void (SocketPoll::*)(), SocketPoll*> >::operator()() /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/thread:243:11
    #14 0xe4888a in std:🧵:_State_impl<std:🧵:_Invoker<std::tuple<void (SocketPoll::*)(), SocketPoll*> > >::_M_run() /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/thread:186:13
    #15 0x7f2c5805fe2e in execute_native_thread_routine /home/vmiklos/lode/packages/gccbuild/x86_64-pc-linux-gnu/libstdc++-v3/src/c++11/../../../../../gcc-7.3.0/libstdc++-v3/src/c++11/thread.cc:83
    #16 0x7f2c57a3c558 in start_thread (/lib64/libpthread.so.0+0x7558)
    #17 0x7f2c5715082e in clone (/lib64/libc.so.6+0xf882e)

SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior /home/vmiklos/lode/opt_private/gcc-7.3.0/lib/gcc/x86_64-pc-linux-gnu/7.3.0/../../../../include/c++/7.3.0/bits/stl_vector.h:798:9 in

Change-Id: Ifaf6b193e9bba480587c2e184df55aa0728bb370
2019-05-27 09:06:38 +02:00
android Revert "Adapt paths to new package name" 2019-05-22 12:06:06 +02:00
bundled/include/LibreOfficeKit lok: update graphic selection callback description 2019-05-20 10:40:05 +02:00
common Get rid of use of GNU libtool 2019-05-24 09:50:16 +02:00
debian Revert "Adapt paths to new package name" 2019-05-22 12:06:06 +02:00
docker No more jake 2019-05-22 15:55:21 +02:00
etc add the /hosting/capabilities endpoint to the example reverse proxy configs 2018-11-30 13:46:33 +01:00
gtk gtk: fix typo 2019-04-23 09:10:18 +02:00
ios Get rid of use of GNU libtool 2019-05-24 09:50:16 +02:00
kit Use consistent terminology in LOG_INF() calls around runLoop() call 2019-05-16 11:41:56 +03:00
loleaflet Add textbox creation to the Impress toolbar. 2019-05-24 17:43:54 +02:00
man
net net: avoid UB in WebSocketHandler::readPayload() 2019-05-27 09:06:38 +02:00
scripts perftrace: fix time parsing issue. 2019-04-19 23:51:26 +01:00
test Fix build issue with --enable-ssl after my previous commit 2019-05-24 12:08:54 +03:00
tools Revert "Adapt paths to new package name" 2019-05-22 12:06:06 +02:00
wsd wsd: avoid UB in DocumentBroker::cancelTileRequests() 2019-05-24 09:04:16 +02:00
.clang-format Add clang-format config from core repo 2018-11-28 16:46:11 +01:00
.clang-tidy
.gitignore Revert "configure: add Boost.Locale library" 2019-03-15 17:28:14 +01:00
.gitreview git-review: Use the hostname instead of alias. 2019-05-17 14:10:33 +02:00
AUTHORS
autogen.sh Get rid of use of GNU libtool 2019-05-24 09:50:16 +02:00
browsersync-config.js Browsersync: Also sync html files 2019-05-20 09:59:45 +02:00
ChangeLog
configure.ac Get rid of use of GNU libtool 2019-05-24 09:50:16 +02:00
COPYING
discovery.xml
favicon.ico
INSTALL
loolkitconfig.xcu change default HelpRootURL to 'https://help.libreoffice.org/help.html?' 2019-04-23 10:05:05 +02:00
loolstat
loolwsd-systemplate-setup Fix domain name resolution from jail by adding required libs to systemplate 2018-12-02 18:32:34 +01:00
loolwsd.service Revert "Adapt paths to new package name" 2019-05-22 12:06:06 +02:00
loolwsd.spec.in Revert "Adapt paths to new package name" 2019-05-22 12:06:06 +02:00
loolwsd.xml.in Revert "Adapt paths to new package name" 2019-05-22 12:06:06 +02:00
Makefile.am Allow 'make run' after 'make build-nocheck' 2019-05-23 16:30:44 +02:00
NEWS
PROBLEMS Tweak problemms. 2019-02-13 18:35:32 +01:00
README
sysconfig.loolwsd

LibreOffice Online.

This project has several components:

wsd/
	The Web Services Daemon - which accepts external connections.

kit/
	The client which lives in its own chroot and renders documents.

common/
	Shared code between these processes.

loleaflet/
	The client side JavaScript component.

It is recommended to read these files:

	wsd/README
	loleaflet/README

Enjoy.