pidgin/pidgin

Use ZSubscription_t in zephyr_triple

2021-01-25, Arkadiy Illarionov
1bad06536f81
Use ZSubscription_t in zephyr_triple

* Change some functions to use `ZSubscription_t`
* Cleanup redundant `zephyr_triple` allocations
* Inline `zephyr_subscribe_failed`
* Replace `find_sub_by_sub` and `find_sub_by_id` with `g_slist_find_custom`
* Rename functions related to `zephyr_triple`

Testing Done:
Compile.

Reviewed at https://reviews.imfreedom.org/r/450/
ZEPHYR_INTERNAL_SOURCES = [
'ZAsyncLocate.c',
'ZCkAuth.c',
'ZCkIfNot.c',
'ZClosePort.c',
'ZCmpUID.c',
'ZCmpUIDP.c',
'ZFlsLocs.c',
'ZFlsSubs.c',
'ZFmtAuth.c',
'ZFmtList.c',
'ZFmtNotice.c',
'ZFmtRaw.c',
'ZFmtRawLst.c',
'ZFmtSmRaw.c',
'ZFreeNot.c',
'ZGetLocs.c',
'ZGetSender.c',
'ZGetSubs.c',
'ZGetWGPort.c',
'ZIfNotice.c',
'ZInit.c',
'ZLocations.c',
'ZMakeAscii.c',
'ZMkAuth.c',
'ZNewLocU.c',
'ZOpenPort.c',
'ZParseNot.c',
'ZPeekNot.c',
'ZPeekPkt.c',
'ZPending.c',
'ZReadAscii.c',
'ZRecvNot.c',
'ZRecvPkt.c',
'ZRetSubs.c',
'ZSendList.c',
'ZSendNot.c',
'ZSendPkt.c',
'ZSetDest.c',
'ZSubs.c',
'ZVariables.c',
'ZWait4Not.c',
'ZhmStat.c',
'Zinternal.c',
'mit-copyright.h',
'mit-sipb-copyright.h',
'zephyr_err.h',
'zephyr_internal.h'
]
ZEPHYR_SOURCES = [
'internal.h',
'sysdep.h',
'zephyr.c',
'zephyr.h',
'zephyr_html.c',
'zephyr_html.h'
]
extdep = krb4
if EXTERNAL_LIBZEPHYR
extdep = ext_zephyr
else
ZEPHYR_SOURCES += ZEPHYR_INTERNAL_SOURCES
endif
if DYNAMIC_ZEPHYR
zephyr_prpl = shared_library('zephyr', ZEPHYR_SOURCES,
c_args : '-Dlint',
dependencies : [extdep, libpurple_dep, glib],
install : true, install_dir : PURPLE_PLUGINDIR)
endif