diff options
Diffstat (limited to 'src/3rdparty/tinycbor')
-rw-r--r-- | src/3rdparty/tinycbor/0001-tst_Encoder-port-away-from-Q_FOREACH.patch | 79 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/qt_attribution.json | 7 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/src/cbor.h | 10 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/src/cborencoder.c | 28 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/src/cborerrorstrings.c | 2 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/src/cborinternal_p.h | 2 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/src/cborparser.c | 6 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/tests/.gitignore | 2 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/tests/encoder/data.cpp | 63 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/tests/encoder/tst_encoder.cpp | 17 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/tests/parser/data.cpp | 5 | ||||
-rw-r--r-- | src/3rdparty/tinycbor/tests/parser/tst_parser.cpp | 2 |
12 files changed, 162 insertions, 61 deletions
diff --git a/src/3rdparty/tinycbor/0001-tst_Encoder-port-away-from-Q_FOREACH.patch b/src/3rdparty/tinycbor/0001-tst_Encoder-port-away-from-Q_FOREACH.patch new file mode 100644 index 0000000000..43c8b1a452 --- /dev/null +++ b/src/3rdparty/tinycbor/0001-tst_Encoder-port-away-from-Q_FOREACH.patch @@ -0,0 +1,79 @@ +From b6e2caf7452bf2b695583196fd7b346c1663d798 Mon Sep 17 00:00:00 2001 +From: Marc Mutz <marc.mutz@qt.io> +Date: Mon, 7 Aug 2023 16:24:13 +0200 +Subject: [PATCH] tst_Encoder: port away from Q_FOREACH + +Qt is defaulting to QT_NO_FOREACH these days, so make sure we +integrate nicely with downstream and fix the single Q_FOREACH/foreach +user, in tst_encoder.cpp. + +Unfortunately, the container's initialization code doesn't exactly +lend itself to making the container const (not even IILE +(Immediately-Invoked Lambda Expression) would help here, due to the +interdependency with `len`), so the idiomatic solution would be to use +std::as_const()/qAsConst(). + +The former is available from C++17, which we don't require, yet, and +the latter is not available under QT_NO_AS_CONST (the default for Qt +these days), so grab the nettle and implement a t17::as_const() that +switches between a manual implementation of std::as_const and the real +thing, depending on __cpp_lib_as_const. The `t17` here mimicks the qNN +(q20::remove_cvref_t/q23::forward_like/etc) mechanism used in Qt +itself for backports, with s/q/t/ because ... _T_inyCbor. + +The t17 implementation is local to tst_encoder.cpp, but can easily be +extracted into a separate header once more users emerge. +--- + tests/encoder/encoder.pro | 2 ++ + tests/encoder/tst_encoder.cpp | 15 ++++++++++++++- + 2 files changed, 16 insertions(+), 1 deletion(-) + +diff --git a/tests/encoder/encoder.pro b/tests/encoder/encoder.pro +index 62d9b7e..180f0d7 100644 +--- a/tests/encoder/encoder.pro ++++ b/tests/encoder/encoder.pro +@@ -3,6 +3,8 @@ SOURCES += tst_encoder.cpp + CONFIG += testcase parallel_test c++11 + QT = core testlib + ++DEFINES += QT_NO_FOREACH QT_NO_AS_CONST ++ + INCLUDEPATH += ../../src + msvc: POST_TARGETDEPS = ../../lib/tinycbor.lib + else: POST_TARGETDEPS += ../../lib/libtinycbor.a +diff --git a/tests/encoder/tst_encoder.cpp b/tests/encoder/tst_encoder.cpp +index 31c2915..61ce9c9 100644 +--- a/tests/encoder/tst_encoder.cpp ++++ b/tests/encoder/tst_encoder.cpp +@@ -29,6 +29,19 @@ + #include <qfloat16.h> + #endif + ++#include <utility> ++namespace t17 { ++#ifdef __cpp_lib_as_const ++ using std::as_const; ++#else ++ template <typename T> ++ constexpr typename std::add_const<T>::type &as_const(T &t) noexcept { return t; } ++ // prevent rvalue arguments: ++ template <typename T> ++ void as_const(const T &&) = delete; ++#endif // __cpp_lib_as_const ++} // namespace t17 ++ + Q_DECLARE_METATYPE(CborError) + namespace QTest { + template<> char *toString<CborError>(const CborError &err) +@@ -153,7 +166,7 @@ CborError encodeVariant(CborEncoder *encoder, const QVariant &v) + CborError err = cbor_encoder_create_array(encoder, &sub, len); + if (err && !isOomError(err)) + return err; +- foreach (const QVariant &v2, list) { ++ for (const QVariant &v2 : t17::as_const(list)) { + err = static_cast<CborError>(err | encodeVariant(&sub, v2)); + if (err && !isOomError(err)) + return err; +-- +2.25.1 + diff --git a/src/3rdparty/tinycbor/qt_attribution.json b/src/3rdparty/tinycbor/qt_attribution.json index 3b9461f6d0..b19c57904b 100644 --- a/src/3rdparty/tinycbor/qt_attribution.json +++ b/src/3rdparty/tinycbor/qt_attribution.json @@ -3,13 +3,14 @@ "Name": "TinyCBOR", "QDocModule": "qtcore", "QtUsage": "Used for QCborStreamReader and QCborStreamWriter.", + "SecurityCritical": true, "Description": "Concise Binary Object Representation (CBOR) Library", "Homepage": "https://github.com/intel/tinycbor", "License": "MIT License", "LicenseId": "MIT", "LicenseFile": "LICENSE", - "DownloadLocation": "https://github.com/thiagomacieira/tinycbor/archive/e6a4fa4862bcc3a6f6b07cf9d9b784d0ab6068b4.tar.gz", - "Version": "0.6+patches", - "Copyright": "Copyright (C) 2015-2019 Intel Corporation" + "DownloadLocation": "https://github.com/intel/tinycbor/archive/v0.6.0/tinycbor-0.6.0.tar.gz", + "Version": "0.6.0", + "Copyright": "Copyright (C) 2015-2021 Intel Corporation" } diff --git a/src/3rdparty/tinycbor/src/cbor.h b/src/3rdparty/tinycbor/src/cbor.h index dd2b4e4f71..be5bbc77a3 100644 --- a/src/3rdparty/tinycbor/src/cbor.h +++ b/src/3rdparty/tinycbor/src/cbor.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal @@ -263,10 +263,10 @@ CBOR_INLINE_API CborError cbor_encode_float(CborEncoder *encoder, float value) CBOR_INLINE_API CborError cbor_encode_double(CborEncoder *encoder, double value) { return cbor_encode_floating_point(encoder, CborDoubleType, &value); } -CBOR_API CborError cbor_encoder_create_array(CborEncoder *encoder, CborEncoder *arrayEncoder, size_t length); -CBOR_API CborError cbor_encoder_create_map(CborEncoder *encoder, CborEncoder *mapEncoder, size_t length); -CBOR_API CborError cbor_encoder_close_container(CborEncoder *encoder, const CborEncoder *containerEncoder); -CBOR_API CborError cbor_encoder_close_container_checked(CborEncoder *encoder, const CborEncoder *containerEncoder); +CBOR_API CborError cbor_encoder_create_array(CborEncoder *parentEncoder, CborEncoder *arrayEncoder, size_t length); +CBOR_API CborError cbor_encoder_create_map(CborEncoder *parentEncoder, CborEncoder *mapEncoder, size_t length); +CBOR_API CborError cbor_encoder_close_container(CborEncoder *parentEncoder, const CborEncoder *containerEncoder); +CBOR_API CborError cbor_encoder_close_container_checked(CborEncoder *parentEncoder, const CborEncoder *containerEncoder); CBOR_INLINE_API uint8_t *_cbor_encoder_get_buffer_pointer(const CborEncoder *encoder) { diff --git a/src/3rdparty/tinycbor/src/cborencoder.c b/src/3rdparty/tinycbor/src/cborencoder.c index 405b0a507d..a51f445159 100644 --- a/src/3rdparty/tinycbor/src/cborencoder.c +++ b/src/3rdparty/tinycbor/src/cborencoder.c @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal @@ -514,7 +514,7 @@ static CborError create_container(CborEncoder *encoder, CborEncoder *container, } /** - * Creates a CBOR array in the CBOR stream provided by \a encoder and + * Creates a CBOR array in the CBOR stream provided by \a parentEncoder and * initializes \a arrayEncoder so that items can be added to the array using * the CborEncoder functions. The array must be terminated by calling either * cbor_encoder_close_container() or cbor_encoder_close_container_checked() @@ -523,17 +523,17 @@ static CborError create_container(CborEncoder *encoder, CborEncoder *container, * The number of items inserted into the array must be exactly \a length items, * otherwise the stream is invalid. If the number of items is not known when * creating the array, the constant \ref CborIndefiniteLength may be passed as - * length instead. + * length instead, and an indefinite length array is created. * * \sa cbor_encoder_create_map */ -CborError cbor_encoder_create_array(CborEncoder *encoder, CborEncoder *arrayEncoder, size_t length) +CborError cbor_encoder_create_array(CborEncoder *parentEncoder, CborEncoder *arrayEncoder, size_t length) { - return create_container(encoder, arrayEncoder, length, ArrayType << MajorTypeShift); + return create_container(parentEncoder, arrayEncoder, length, ArrayType << MajorTypeShift); } /** - * Creates a CBOR map in the CBOR stream provided by \a encoder and + * Creates a CBOR map in the CBOR stream provided by \a parentEncoder and * initializes \a mapEncoder so that items can be added to the map using * the CborEncoder functions. The map must be terminated by calling either * cbor_encoder_close_container() or cbor_encoder_close_container_checked() @@ -542,7 +542,7 @@ CborError cbor_encoder_create_array(CborEncoder *encoder, CborEncoder *arrayEnco * The number of pair of items inserted into the map must be exactly \a length * items, otherwise the stream is invalid. If the number is not known * when creating the map, the constant \ref CborIndefiniteLength may be passed as - * length instead. + * length instead, and an indefinite length map is created. * * \b{Implementation limitation:} TinyCBOR cannot encode more than SIZE_MAX/2 * key-value pairs in the stream. If the length \a length is larger than this @@ -551,11 +551,11 @@ CborError cbor_encoder_create_array(CborEncoder *encoder, CborEncoder *arrayEnco * * \sa cbor_encoder_create_array */ -CborError cbor_encoder_create_map(CborEncoder *encoder, CborEncoder *mapEncoder, size_t length) +CborError cbor_encoder_create_map(CborEncoder *parentEncoder, CborEncoder *mapEncoder, size_t length) { if (length != CborIndefiniteLength && length > SIZE_MAX / 2) return CborErrorDataTooLarge; - return create_container(encoder, mapEncoder, length, MapType << MajorTypeShift); + return create_container(parentEncoder, mapEncoder, length, MapType << MajorTypeShift); } /** @@ -570,19 +570,19 @@ CborError cbor_encoder_create_map(CborEncoder *encoder, CborEncoder *mapEncoder, * * \sa cbor_encoder_create_array(), cbor_encoder_create_map() */ -CborError cbor_encoder_close_container(CborEncoder *encoder, const CborEncoder *containerEncoder) +CborError cbor_encoder_close_container(CborEncoder *parentEncoder, const CborEncoder *containerEncoder) { // synchronise buffer state with that of the container - encoder->end = containerEncoder->end; - encoder->data = containerEncoder->data; + parentEncoder->end = containerEncoder->end; + parentEncoder->data = containerEncoder->data; if (containerEncoder->flags & CborIteratorFlag_UnknownLength) - return append_byte_to_buffer(encoder, BreakByte); + return append_byte_to_buffer(parentEncoder, BreakByte); if (containerEncoder->remaining != 1) return containerEncoder->remaining == 0 ? CborErrorTooManyItems : CborErrorTooFewItems; - if (!encoder->end) + if (!parentEncoder->end) return CborErrorOutOfMemory; /* keep the state */ return CborNoError; diff --git a/src/3rdparty/tinycbor/src/cborerrorstrings.c b/src/3rdparty/tinycbor/src/cborerrorstrings.c index 9c2e9750c6..44f766a3c4 100644 --- a/src/3rdparty/tinycbor/src/cborerrorstrings.c +++ b/src/3rdparty/tinycbor/src/cborerrorstrings.c @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal diff --git a/src/3rdparty/tinycbor/src/cborinternal_p.h b/src/3rdparty/tinycbor/src/cborinternal_p.h index 8dc0c13d3c..16269e6301 100644 --- a/src/3rdparty/tinycbor/src/cborinternal_p.h +++ b/src/3rdparty/tinycbor/src/cborinternal_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal diff --git a/src/3rdparty/tinycbor/src/cborparser.c b/src/3rdparty/tinycbor/src/cborparser.c index 074af11209..80c44c7e13 100644 --- a/src/3rdparty/tinycbor/src/cborparser.c +++ b/src/3rdparty/tinycbor/src/cborparser.c @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal @@ -232,7 +232,7 @@ static CborError preparse_value(CborValue *it) case SinglePrecisionFloat: case DoublePrecisionFloat: it->flags |= CborIteratorFlag_IntegerValueTooLarge; - /* fall through */ + Q_FALLTHROUGH(); case TrueValue: case NullValue: case UndefinedValue: @@ -1147,7 +1147,7 @@ static CborError get_string_chunk(CborValue *it, const void **bufferptr, size_t */ CborError _cbor_value_get_string_chunk(const CborValue *value, const void **bufferptr, - size_t *len, CborValue *next) + size_t *len, CborValue *next) { CborValue tmp; if (!next) diff --git a/src/3rdparty/tinycbor/tests/.gitignore b/src/3rdparty/tinycbor/tests/.gitignore index e65577d287..f5db2a8224 100644 --- a/src/3rdparty/tinycbor/tests/.gitignore +++ b/src/3rdparty/tinycbor/tests/.gitignore @@ -5,6 +5,8 @@ release target_wrapper.* # The executables +c90/c90 +c90/c90.exe cpp/cpp cpp/cpp.exe encoder/encoder diff --git a/src/3rdparty/tinycbor/tests/encoder/data.cpp b/src/3rdparty/tinycbor/tests/encoder/data.cpp index df1471548e..dc7c6a91a1 100644 --- a/src/3rdparty/tinycbor/tests/encoder/data.cpp +++ b/src/3rdparty/tinycbor/tests/encoder/data.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal @@ -24,7 +24,29 @@ #include <QtTest> -static float myNaNf() +struct NegativeInteger { quint64 abs; }; +Q_DECLARE_METATYPE(NegativeInteger) + +struct SimpleType { uint8_t type; }; +Q_DECLARE_METATYPE(SimpleType) + +struct Float16Standin { uint16_t val; }; +Q_DECLARE_METATYPE(Float16Standin) + +struct Tag { CborTag tag; QVariant tagged; }; +Q_DECLARE_METATYPE(Tag) + +typedef QVector<QPair<QVariant, QVariant>> Map; +Q_DECLARE_METATYPE(Map) + +struct IndeterminateLengthArray : QVariantList { using QVariantList::QVariantList; }; +struct IndeterminateLengthMap : Map { using Map::Map; }; +Q_DECLARE_METATYPE(IndeterminateLengthArray) +Q_DECLARE_METATYPE(IndeterminateLengthMap) + +namespace { + +float myNaNf() { uint32_t v = 0x7fc00000; float f; @@ -33,7 +55,7 @@ static float myNaNf() return f; } -static float myInff() +float myInff() { uint32_t v = 0x7f800000; float f; @@ -42,7 +64,7 @@ static float myInff() return f; } -static float myNInff() +float myNInff() { uint32_t v = 0xff800000; float f; @@ -51,7 +73,7 @@ static float myNInff() return f; } -static double myNaN() +double myNaN() { uint64_t v = UINT64_C(0x7ff8000000000000); double f; @@ -60,7 +82,7 @@ static double myNaN() return f; } -static double myInf() +double myInf() { uint64_t v = UINT64_C(0x7ff0000000000000); double f; @@ -69,7 +91,7 @@ static double myInf() return f; } -static double myNInf() +double myNInf() { uint64_t v = UINT64_C(0xfff0000000000000); double f; @@ -83,36 +105,17 @@ template <size_t N> QByteArray raw(const char (&data)[N]) return QByteArray::fromRawData(data, N - 1); } -struct NegativeInteger { quint64 abs; }; -Q_DECLARE_METATYPE(NegativeInteger) - -struct SimpleType { uint8_t type; }; -Q_DECLARE_METATYPE(SimpleType) - -struct Float16Standin { uint16_t val; }; -Q_DECLARE_METATYPE(Float16Standin) - -struct Tag { CborTag tag; QVariant tagged; }; -Q_DECLARE_METATYPE(Tag) - template <typename... Args> QVariant make_list(const Args &... args) { return QVariantList{args...}; } -typedef QVector<QPair<QVariant, QVariant>> Map; -Q_DECLARE_METATYPE(Map) QVariant make_map(const std::initializer_list<QPair<QVariant, QVariant>> &list) { return QVariant::fromValue(Map(list)); } -struct IndeterminateLengthArray : QVariantList { using QVariantList::QVariantList; }; -struct IndeterminateLengthMap : Map { using Map::Map; }; -Q_DECLARE_METATYPE(IndeterminateLengthArray) -Q_DECLARE_METATYPE(IndeterminateLengthMap) - QVariant make_ilarray(const std::initializer_list<QVariant> &list) { return QVariant::fromValue(IndeterminateLengthArray(list)); @@ -239,9 +242,9 @@ void addFixedData() QTest::newRow("0.f16") << raw("\xf9\0\0") << QVariant::fromValue(qfloat16(0)); QTest::newRow("-1.f16") << raw("\xf9\xbc\0") << QVariant::fromValue(qfloat16(-1)); QTest::newRow("1.5f16") << raw("\xf9\x3e\0") << QVariant::fromValue(qfloat16(1.5)); - QTest::newRow("nan_f16") << raw("\xf9\x7e\0") << QVariant::fromValue<qfloat16>(myNaNf()); - QTest::newRow("-inf_f16") << raw("\xf9\xfc\0") << QVariant::fromValue<qfloat16>(myNInff()); - QTest::newRow("+inf_f16") << raw("\xf9\x7c\0") << QVariant::fromValue<qfloat16>(myInff()); + QTest::newRow("nan_f16") << raw("\xf9\x7e\0") << QVariant::fromValue<qfloat16>(qfloat16(myNaNf())); + QTest::newRow("-inf_f16") << raw("\xf9\xfc\0") << QVariant::fromValue<qfloat16>(qfloat16(myNInff())); + QTest::newRow("+inf_f16") << raw("\xf9\x7c\0") << QVariant::fromValue<qfloat16>(qfloat16(myInff())); #endif QTest::newRow("0.f") << raw("\xfa\0\0\0\0") << QVariant::fromValue(0.f); @@ -343,4 +346,4 @@ void addArraysAndMaps() QTest::newRow("array-1(map)") << raw("\x81\xc1\xa0") << make_list(QVariant::fromValue(Tag{1, make_map({})})); QTest::newRow("map-1(2):3(4)") << raw("\xa1\xc1\2\xc3\4") << make_map({{QVariant::fromValue(Tag{1, 2}), QVariant::fromValue(Tag{3, 4})}}); } - +} // namespace diff --git a/src/3rdparty/tinycbor/tests/encoder/tst_encoder.cpp b/src/3rdparty/tinycbor/tests/encoder/tst_encoder.cpp index 458f55eb10..61ce9c995c 100644 --- a/src/3rdparty/tinycbor/tests/encoder/tst_encoder.cpp +++ b/src/3rdparty/tinycbor/tests/encoder/tst_encoder.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2016 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal @@ -29,6 +29,19 @@ #include <qfloat16.h> #endif +#include <utility> +namespace t17 { +#ifdef __cpp_lib_as_const + using std::as_const; +#else + template <typename T> + constexpr typename std::add_const<T>::type &as_const(T &t) noexcept { return t; } + // prevent rvalue arguments: + template <typename T> + void as_const(const T &&) = delete; +#endif // __cpp_lib_as_const +} // namespace t17 + Q_DECLARE_METATYPE(CborError) namespace QTest { template<> char *toString<CborError>(const CborError &err) @@ -153,7 +166,7 @@ CborError encodeVariant(CborEncoder *encoder, const QVariant &v) CborError err = cbor_encoder_create_array(encoder, &sub, len); if (err && !isOomError(err)) return err; - foreach (const QVariant &v2, list) { + for (const QVariant &v2 : t17::as_const(list)) { err = static_cast<CborError>(err | encodeVariant(&sub, v2)); if (err && !isOomError(err)) return err; diff --git a/src/3rdparty/tinycbor/tests/parser/data.cpp b/src/3rdparty/tinycbor/tests/parser/data.cpp index 0fe2e22544..c99160ad31 100644 --- a/src/3rdparty/tinycbor/tests/parser/data.cpp +++ b/src/3rdparty/tinycbor/tests/parser/data.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal @@ -28,6 +28,8 @@ Q_DECLARE_METATYPE(CborError) +namespace { + template <size_t N> QByteArray raw(const char (&data)[N]) { return QByteArray::fromRawData(data, N - 1); @@ -605,3 +607,4 @@ void addValidationData(size_t minInvalid = ~size_t(0)) // This test technically tests the dumper, not the parser. QTest::newRow("string-utf8-chunk-split") << raw("\x81\x7f\x61\xc2\x61\xa0\xff") << 0 << CborErrorInvalidUtf8TextString; } +} // namespace diff --git a/src/3rdparty/tinycbor/tests/parser/tst_parser.cpp b/src/3rdparty/tinycbor/tests/parser/tst_parser.cpp index b8e51619b8..91a65a00ba 100644 --- a/src/3rdparty/tinycbor/tests/parser/tst_parser.cpp +++ b/src/3rdparty/tinycbor/tests/parser/tst_parser.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2019 Intel Corporation +** Copyright (C) 2021 Intel Corporation ** ** Permission is hereby granted, free of charge, to any person obtaining a copy ** of this software and associated documentation files (the "Software"), to deal |