mirror of
https://forge.fsky.io/lda/Parsee.git
synced 2026-03-13 10:55:10 +00:00
[MOD/META] Clarify LICENSE more, fix chatstates
This commit is contained in:
parent
63285ac24a
commit
2324f9afc0
4 changed files with 48 additions and 16 deletions
25
CHANGELOG.md
25
CHANGELOG.md
|
|
@ -6,6 +6,12 @@ Dates are to be written as DD/MM/YYYY. Please update the
|
|||
changelog as you go, no one wants to keep track of every
|
||||
commit done between releases.
|
||||
|
||||
## Release
|
||||
*There is currently no full releases of Parsee*
|
||||
|
||||
## Beta
|
||||
*There is currently no beta releases of Parsee*
|
||||
|
||||
## Alpha
|
||||
### v0.1.0[tomboyish-bridges-adventure] <9/9/2024>
|
||||
Nothing much to say, but this is the first alpha release
|
||||
|
|
@ -18,18 +24,19 @@ of Parsee. May occasionally deadlock.
|
|||
*NONE*
|
||||
|
||||
### v0.1.1[star-of-hope] <X/X/XXXX>
|
||||
Fixes some media metadata things, and replaces the build
|
||||
system of Parsee.
|
||||
Fixes some media metadata things, replaces the build system,
|
||||
and speeds up Parsee a tad bit.
|
||||
#### New things
|
||||
- Start dealing with some basic PEP-based avatars.
|
||||
#### Bugfixes
|
||||
- Adds more information to media events so that clients can behave.
|
||||
- Fixes issues where SIGPIPE can actually just kill Parsee.
|
||||
- Allows MbedTLS through a specific Cytoplasm patch.
|
||||
- "Lone" XMPP messages no longer render weirdly on Element Android's
|
||||
weird rendering.
|
||||
- Start fixing bug where Parsee takes several seconds to send a
|
||||
message coming from XMPP
|
||||
#### Bugfixes
|
||||
- Adds more information to media events so that clients can
|
||||
behave.
|
||||
- Fixes issues where SIGPIPE can actually just kill Parsee.
|
||||
- "Lone" XMPP messages no longer render weirdly on Element
|
||||
Android's weird rendering.
|
||||
- Start fixing bug where Parsee takes several seconds to send
|
||||
a message coming from XMPP
|
||||
#### Deprecated features
|
||||
- The old `build.c` and `Makefile`s used for building are removed,
|
||||
and replaced by the `configure.c` C file(/script via TCC).
|
||||
|
|
|
|||
2
LICENSE
2
LICENSE
|
|
@ -1,6 +1,6 @@
|
|||
For the files src/include/Unistring.h, src/Unistr.h rc/Parsee/HMAC.c, src/XML/*, tools/*, src/include/XML.h, etc/*, and Makefile,
|
||||
see COPYING.CC0.
|
||||
For any other file in src/, see COPYING.AGPL as the primary license.
|
||||
For any other file in src/, see COPYING.AGPL as the primary license(AGPL-3.0-or-later)
|
||||
|
||||
As Parsee depends on Cytoplasm, its license is left here in COPYING.CYTO
|
||||
|
||||
|
|
|
|||
|
|
@ -30,8 +30,9 @@ ASType(const ParseeConfig *c, char *user, char *room, bool status)
|
|||
|
||||
json = HashMapCreate();
|
||||
HashMapSet(json, "typing", JsonValueBoolean(status));
|
||||
/* If someone types for 10 minutes straight, they got something weird man. */
|
||||
HashMapSet(json, "timeout", JsonValueBoolean(10 MINUTES));
|
||||
/* If someone types for 5 minutes straight, they got something
|
||||
* weird man. */
|
||||
HashMapSet(json, "timeout", JsonValueInteger(5 MINUTES));
|
||||
ctx = ParseeCreateRequest(c, HTTP_PUT, path);
|
||||
Free(path);
|
||||
ASAuthenticateRequest(c, ctx);
|
||||
|
|
|
|||
|
|
@ -20,14 +20,22 @@ LazyRegister(ParseeData *data, char *mxid, char *name)
|
|||
{
|
||||
ASRegisterUser(data->config, mxid);
|
||||
ref = DbCreate(data->db, 2, "users", hash);
|
||||
HashMapSet(DbJson(ref), "mxid", JsonValueString(mxid));
|
||||
HashMapSet(DbJson(ref), "ts", JsonValueInteger(UtilTsMillis()));
|
||||
if (ref)
|
||||
{
|
||||
HashMapSet(DbJson(ref), "mxid", JsonValueString(mxid));
|
||||
HashMapSet(DbJson(ref),
|
||||
"ts", JsonValueInteger(UtilTsMillis())
|
||||
);
|
||||
}
|
||||
}
|
||||
dbname = GrabString(DbJson(ref), 1, "name");
|
||||
if (name && !StrEquals(dbname, name))
|
||||
{
|
||||
ASSetName(data->config, mxid, name);
|
||||
HashMapSet(DbJson(ref), "name", JsonValueString(name));
|
||||
if (ref)
|
||||
{
|
||||
HashMapSet(DbJson(ref), "name", JsonValueString(name));
|
||||
}
|
||||
}
|
||||
DbUnlock(data->db, ref);
|
||||
Free(hash);
|
||||
|
|
@ -101,8 +109,24 @@ ProcessChatstates(ParseeData *args, XMLElement *stanza)
|
|||
mroom_id = NULL;
|
||||
from_matrix = NULL;
|
||||
}
|
||||
if (XMLookForTKV(stanza, "paused", "xmlns", CHAT_STATES) ||
|
||||
XMLookForTKV(stanza, "received", "xmlns", "urn:xmpp:receipts") ||
|
||||
if (XMLookForTKV(stanza, "paused", "xmlns", CHAT_STATES))
|
||||
{
|
||||
char *latest = NULL;
|
||||
from_matrix = ParseeGetBridgedUser(args, stanza);
|
||||
mroom_id = ParseeGetBridgedRoom(args, stanza);
|
||||
|
||||
latest = ParseeLookupHead(mroom_id);
|
||||
|
||||
ASType(args->config, from_matrix, mroom_id, false);
|
||||
ASPresence(args->config, from_matrix, mroom_id, latest);
|
||||
|
||||
Free(from_matrix);
|
||||
Free(latest);
|
||||
Free(mroom_id);
|
||||
mroom_id = NULL;
|
||||
from_matrix = NULL;
|
||||
}
|
||||
if (XMLookForTKV(stanza, "received", "xmlns", "urn:xmpp:receipts") ||
|
||||
XMLookForTKV(stanza, "displayed", "xmlns", "urn:xmpp:chat-markers:0"))
|
||||
{
|
||||
/* TODO: Use stanza ID if possible */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue