update for tdlib v1.7.0

This commit is contained in:
Aleksandr Zelenin 2020-11-30 12:33:47 +03:00
parent a5d1c7ffe7
commit 4a26afe3b0
9 changed files with 9127 additions and 2063 deletions

View file

@ -1,4 +1,4 @@
TAG := v1.6.0 TAG := v1.7.0
schema-update: schema-update:
curl https://raw.githubusercontent.com/tdlib/td/${TAG}/td/generate/scheme/td_api.tl 2>/dev/null > ./data/td_api.tl curl https://raw.githubusercontent.com/tdlib/td/${TAG}/td/generate/scheme/td_api.tl 2>/dev/null > ./data/td_api.tl

View file

@ -1,6 +1,6 @@
# go-tdlib # go-tdlib
Go wrapper for [TDLib (Telegram Database Library)](https://github.com/tdlib/td) with full support of TDLib v1.6.0 Go wrapper for [TDLib (Telegram Database Library)](https://github.com/tdlib/td) with full support of TDLib v1.7.0
## TDLib installation ## TDLib installation

File diff suppressed because it is too large Load diff

View file

@ -5,6 +5,6 @@ package client
/* /*
#cgo linux CFLAGS: -I/usr/local/include #cgo linux CFLAGS: -I/usr/local/include
#cgo linux LDFLAGS: -L/usr/local/lib -ltdjson_static -ltdjson_private -ltdclient -ltdcore -ltdactor -ltddb -ltdsqlite -ltdnet -ltdutils -lstdc++ -lssl -lcrypto -ldl -lz -lm #cgo linux LDFLAGS: -L/usr/local/lib -ltdjson_static -ltdjson_private -ltdclient -ltdcore -ltdactor -ltdapi -ltddb -ltdsqlite -ltdnet -ltdutils -lstdc++ -lssl -lcrypto -ldl -lz -lm
*/ */
import "C" import "C"

View file

@ -144,7 +144,11 @@ func (jsonInt64 JsonInt64) MarshalJSON() ([]byte, error) {
// UnmarshalJSON unmarshals from json // UnmarshalJSON unmarshals from json
func (jsonInt64 *JsonInt64) UnmarshalJSON(data []byte) error { func (jsonInt64 *JsonInt64) UnmarshalJSON(data []byte) error {
jsonBigInt, err := strconv.ParseInt(string(data[1:len(data)-1]), 10, 64) if len(data) > 2 && data[0] == '"' && data[len(data)-1] == '"' {
data = data[1 : len(data)-1]
}
jsonBigInt, err := strconv.ParseInt(string(data), 10, 64)
if err != nil { if err != nil {
return err return err
} }

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff