178 lines
7.8 KiB
Diff
178 lines
7.8 KiB
Diff
diff -Naur python_ics-2.15/src/methods.cpp python2-build-x86_64/src/methods.cpp
|
|
--- python_ics-2.15/src/methods.cpp 2018-12-21 13:58:55.346242300 +0300
|
|
+++ python2-build-x86_64/src/methods.cpp 2018-12-21 13:56:07.033930100 +0300
|
|
@@ -38,7 +38,7 @@
|
|
extern PyTypeObject spy_message_object_type;
|
|
// __func__, __FUNCTION__ and __PRETTY_FUNCTION__ are not preprocessor macros.
|
|
// but MSVC doesn't follow c standard and treats __FUNCTION__ as a string literal macro...
|
|
-#if (defined(_WIN32) || defined(__WIN32__))
|
|
+#if defined(_MSC_VER)
|
|
#define arg_parse(a,f) a f
|
|
#else
|
|
const char* arg_parse(const char* args, const char* func)
|
|
@@ -182,7 +182,7 @@
|
|
if (device_type && PyLong_Check(device_type))
|
|
#else
|
|
if (device_type && PyInt_Check(device_type))
|
|
-#endif PY_MAJOR_VERSION >= 3
|
|
+#endif // PY_MAJOR_VERSION >= 3
|
|
{
|
|
legacy_dev_type = PyLong_AsLong(device_type);
|
|
use_legacy_device_type = true;
|
|
@@ -1297,7 +1297,7 @@
|
|
}
|
|
|
|
#define _get_vcan3_settings(handle) __get_vcan3_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_vcan3_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_vcan3_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&vcan3_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1334,7 +1334,7 @@
|
|
}
|
|
|
|
#define _get_vcan412_settings(handle) __get_vcan412_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_vcan412_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_vcan412_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&vcan412_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1377,7 +1377,7 @@
|
|
|
|
#if 0 // Not implemented in 802
|
|
#define _get_vcan4_settings(handle) __get_vcan4_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_vcan4_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_vcan4_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&vcan4_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1430,7 +1430,7 @@
|
|
#endif // 0
|
|
|
|
#define _get_vcanrf_settings(handle) __get_vcanrf_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_vcanrf_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_vcanrf_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&vcanrf_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1496,7 +1496,7 @@
|
|
}
|
|
|
|
#define _get_fire_settings(handle) __get_fire_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_fire_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_fire_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&fire_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1593,7 +1593,7 @@
|
|
}
|
|
|
|
#define _get_cyan_settings(handle) __get_cyan_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_cyan_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_cyan_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&cyan_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1706,7 +1706,7 @@
|
|
}
|
|
|
|
#define _get_rad_galaxy_settings(handle) __get_rad_galaxy_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_rad_galaxy_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_rad_galaxy_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&rad_galaxy_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1792,7 +1792,7 @@
|
|
}
|
|
|
|
#define _get_vividcan_settings(handle) __get_vividcan_settings(handle, __FUNCTION__);
|
|
-static PyObject* __get_vividcan_settings(ICS_HANDLE handle, char* func_name)
|
|
+static PyObject* __get_vividcan_settings(ICS_HANDLE handle, const char* func_name)
|
|
{
|
|
PyObject* settings = PyObject_CallObject((PyObject*)&vividcan_settings_object_type, NULL);
|
|
if (!settings) {
|
|
@@ -1914,7 +1914,7 @@
|
|
return set_ics_exception(exception_runtime_error(), "This is a bug!");
|
|
}
|
|
|
|
-static PyObject* __set_vcan3_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_vcan3_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -1945,7 +1945,7 @@
|
|
}
|
|
#define _set_vcan3_settings(handle, settings, save) __set_vcan3_settings(handle, settings, save, __FUNCTION__);
|
|
|
|
-static PyObject* __set_vcan412_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_vcan412_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -1982,7 +1982,7 @@
|
|
#define _set_vcan412_settings(handle, settings, save) __set_vcan412_settings(handle, settings, save, __FUNCTION__);
|
|
|
|
#if 0 // not implemented in 802
|
|
-static PyObject* __set_vcan4_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_vcan4_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -2029,7 +2029,7 @@
|
|
#define _set_vcan4_settings(handle, settings, save) __set_vcan4_settings(handle, settings, save, __FUNCTION__);
|
|
#endif // 0
|
|
|
|
-static PyObject* __set_vcanrf_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_vcanrf_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -2081,7 +2081,7 @@
|
|
}
|
|
#define _set_vcanrf_settings(handle, settings, save) __set_vcanrf_settings(handle, settings, save, __FUNCTION__);
|
|
|
|
-static PyObject* __set_fire_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_fire_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -2156,7 +2156,7 @@
|
|
}
|
|
#define _set_fire_settings(handle, settings, save) __set_fire_settings(handle, settings, save, __FUNCTION__);
|
|
|
|
-static PyObject* __set_cyan_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_cyan_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -2248,7 +2248,7 @@
|
|
}
|
|
#define _set_cyan_settings(handle, settings, save) __set_cyan_settings(handle, settings, save, __FUNCTION__);
|
|
|
|
-static PyObject* __set_rad_galaxy_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_rad_galaxy_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
@@ -2324,7 +2324,7 @@
|
|
}
|
|
#define _set_rad_galaxy_settings(handle, settings, save) __set_rad_galaxy_settings(handle, settings, save, __FUNCTION__);
|
|
|
|
-static PyObject* __set_vividcan_settings(ICS_HANDLE handle, PyObject* settings, int& save, char* func_name)
|
|
+static PyObject* __set_vividcan_settings(ICS_HANDLE handle, PyObject* settings, int& save, const char* func_name)
|
|
{
|
|
try
|
|
{
|
|
diff -Naur python_ics-2.15/include/object_vcanrf_settings.h python2-build-x86_64/include/object_vcanrf_settings.h
|
|
--- python_ics-2.15/include/object_vcanrf_settings.h 2018-07-16 21:07:55.000000000 +0300
|
|
+++ python2-build-x86_64/include/object_vcanrf_settings.h 2018-12-21 13:24:14.969597400 +0300
|
|
@@ -63,7 +63,7 @@
|
|
{ "idle_wakeup_network_enables_1", T_USHORT, offsetof(vcanrf_settings_object, s.idle_wakeup_network_enables_1), 0, "" },
|
|
{ "idle_wakeup_network_enables_2", T_USHORT, offsetof(vcanrf_settings_object, s.idle_wakeup_network_enables_2), 0, "" },
|
|
//{ "reservedZero", T_USHORT, offsetof(vcanrf_settings_object, s.reservedZero), 0, "" },
|
|
- { NULL, 0, 0, 0, 0 },
|
|
+ { NULL, 0, 0, 0, NULL },
|
|
};
|
|
|
|
static int vcanrf_settings_object_init(vcanrf_settings_object* self, PyObject* args, PyObject* kwds)
|