An extremely high performance HTTP framework.
openkitten / lynx Goto Github PK
View Code? Open in Web Editor NEWThe OpenKitten HTTP Framework
The OpenKitten HTTP Framework
Yarn isn't going to work
Building 2a6ed87
telnet
127.0.0.1 8080telnet 127.0.0.1 8080
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
self.readSource.setEventHandler(qos: .userInteractive) {
will call once (though occasionally twice) wherelet read = Darwin.recv(self.descriptor, self.incomingBuffer.pointer, Int(UInt16.max), 0)
let read = Darwin.recv(self.descriptor, self.incomingBuffer.pointer, Int(UInt16.max), 0)
resolves to a small int (have seen 18, 12, or 39)call stack:
#0 0x0000000100cdd5a0 in parsePath #1 () in RequestPlaceholder.parse(_:len:) at /Users/jameswilliamgraham/Lynx/Sources/Lynx/HTTP/HTTPParser.swift:151
#1 0x0000000100cdb4ee in RequestPlaceholder.parse(_:len:) at /Users/jameswilliamgraham/Lynx/Sources/Lynx/HTTP/HTTPParser.swift:189
#2 0x0000000100cdeea2 in closure #1 in HTTPServer.connection(from:) at /Users/jameswilliamgraham/Lynx/Sources/Lynx/HTTP/HTTPServer.swift:47
#3 0x0000000100cdf02e in partial apply for closure #1 in HTTPServer.connection(from:) ()
#4 0x0000000100d0eee6 in closure #1 in ClientHolder.listen() at /Users/jameswilliamgraham/Lynx/Sources/Lynx/Sockets/TCPClient.swift:89
#5 0x0000000100d0ef4c in partial apply for closure #1 in ClientHolder.listen() ()
#6 0x0000000100d0e9f9 in thunk for @callee_owned () -> () ()
#7 0x0000000100d861f1 in _dispatch_block_async_invoke ()
#8 0x0000000100d7078c in _dispatch_client_callout ()
#9 0x0000000100d869fb in _dispatch_continuation_pop ()
#10 0x0000000100d7c64a in _dispatch_source_latch_and_call ()
#11 0x0000000100d735da in _dispatch_source_invoke ()
#12 0x0000000100d86721 in _dispatch_continuation_pop ()
#13 0x0000000100d7ddfc in _dispatch_async_redirect_invoke ()
#14 0x0000000100d72a0c in _dispatch_root_queue_drain ()
#15 0x0000000100d7271d in _dispatch_worker_thread3 ()
#16 0x0000000100de77da in _pthread_wqthread ()
#17 0x0000000100de72b5 in start_wqthread ()
The crash occurs in parsing paths
self.path = Path(path: UnsafeBufferPointer(start: buffer.baseAddress, count: buffer.count &- 1), query: nil)
(lldb) po buffer.count
0
seems like checking the buffer size before making a pointer would solve this, though I'd like to understand more why it's happening
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.