Mercurial > hg > orthanc
annotate OrthancFramework/Resources/Patches/dcmtk-3.6.5.patch @ 5489:50910d241dd7
fix for mingw
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 09 Jan 2024 18:36:55 +0100 |
parents | dd17d37ad950 |
children |
rev | line source |
---|---|
4018
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
1 diff -urEb dcmtk-3.6.5.orig/CMake/GenerateDCMTKConfigure.cmake dcmtk-3.6.5/CMake/GenerateDCMTKConfigure.cmake |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
2 --- dcmtk-3.6.5.orig/CMake/GenerateDCMTKConfigure.cmake 2020-11-04 18:27:08.984662119 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
3 +++ dcmtk-3.6.5/CMake/GenerateDCMTKConfigure.cmake 2020-11-04 18:27:48.232609773 +0100 |
4018
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
4 @@ -169,6 +169,8 @@ |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
5 endif() |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
6 |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
7 # Check the sizes of various types |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
8 +if (NOT CMAKE_SYSTEM_NAME STREQUAL "Emscripten") |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
9 + # This doesn't work for wasm, Orthanc defines the macros manually |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
10 include (CheckTypeSize) |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
11 CHECK_TYPE_SIZE("char" SIZEOF_CHAR) |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
12 CHECK_TYPE_SIZE("double" SIZEOF_DOUBLE) |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
13 @@ -177,6 +179,7 @@ |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
14 CHECK_TYPE_SIZE("long" SIZEOF_LONG) |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
15 CHECK_TYPE_SIZE("short" SIZEOF_SHORT) |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
16 CHECK_TYPE_SIZE("void*" SIZEOF_VOID_P) |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
17 +endif() |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
18 |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
19 # Check for include files, libraries, and functions |
9d2d2c1afcec
fix build with recent versions of Emscripten
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3778
diff
changeset
|
20 include("${DCMTK_CMAKE_INCLUDE}CMake/dcmtkTryCompile.cmake") |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
21 diff -urEb dcmtk-3.6.5.orig/dcmdata/include/dcmtk/dcmdata/dcdict.h dcmtk-3.6.5/dcmdata/include/dcmtk/dcmdata/dcdict.h |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
22 --- dcmtk-3.6.5.orig/dcmdata/include/dcmtk/dcmdata/dcdict.h 2020-11-04 18:27:08.972662135 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
23 +++ dcmtk-3.6.5/dcmdata/include/dcmtk/dcmdata/dcdict.h 2020-11-04 18:27:48.232609773 +0100 |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
24 @@ -152,6 +152,12 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
25 /// returns an iterator to the end of the repeating tag dictionary |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
26 DcmDictEntryListIterator repeatingEnd() { return repDict.end(); } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
27 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
28 + // Function by the Orthanc project to load a dictionary from a |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
29 + // memory buffer, which is necessary in sandboxed |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
30 + // environments. This is an adapted version of |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
31 + // DcmDataDictionary::loadDictionary(). |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
32 + OFBool loadFromMemory(const std::string& content, OFBool errorIfAbsent = OFTrue); |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
33 + |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
34 private: |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
35 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
36 /** private undefined assignment operator |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
37 diff -urEb dcmtk-3.6.5.orig/dcmdata/libsrc/dcdict.cc dcmtk-3.6.5/dcmdata/libsrc/dcdict.cc |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
38 --- dcmtk-3.6.5.orig/dcmdata/libsrc/dcdict.cc 2020-11-04 18:27:08.976662131 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
39 +++ dcmtk-3.6.5/dcmdata/libsrc/dcdict.cc 2020-11-04 18:27:48.232609773 +0100 |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
40 @@ -900,3 +900,6 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
41 wrlock().clear(); |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
42 wrunlock(); |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
43 } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
44 + |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
45 + |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
46 +#include "dcdict_orthanc.cc" |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
47 diff -urEb dcmtk-3.6.5.orig/dcmdata/libsrc/dcpxitem.cc dcmtk-3.6.5/dcmdata/libsrc/dcpxitem.cc |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
48 --- dcmtk-3.6.5.orig/dcmdata/libsrc/dcpxitem.cc 2020-11-04 18:27:08.976662131 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
49 +++ dcmtk-3.6.5/dcmdata/libsrc/dcpxitem.cc 2020-11-04 18:27:48.232609773 +0100 |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
50 @@ -36,6 +36,9 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
51 #include "dcmtk/dcmdata/dcostrma.h" /* for class DcmOutputStream */ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
52 #include "dcmtk/dcmdata/dcwcache.h" /* for class DcmWriteCache */ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
53 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
54 +#undef max |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
55 +#include "dcmtk/ofstd/oflimits.h" |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
56 + |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
57 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
58 // ******************************** |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
59 |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
60 diff -urEb dcmtk-3.6.5.orig/dcmnet/libsrc/dulparse.cc dcmtk-3.6.5/dcmnet/libsrc/dulparse.cc |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
61 --- dcmtk-3.6.5.orig/dcmnet/libsrc/dulparse.cc 2020-11-04 18:27:09.004662093 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
62 +++ dcmtk-3.6.5/dcmnet/libsrc/dulparse.cc 2020-11-04 18:29:41.832458294 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
63 @@ -736,7 +736,14 @@ |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
64 << " is larger than maximum allowed UID length " << DICOM_UI_LENGTH << " (will use 64 bytes max)"); |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
65 UIDLength = DICOM_UI_LENGTH; |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
66 } |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
67 - OFStandard::strlcpy(role->SOPClassUID, (char*)buf, UIDLength+1 /* +1 for 0-byte */); |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
68 + |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
69 + // Patch from: https://github.com/DCMTK/dcmtk/commit/10428a74e74c003b3ff31c992f658d528b626fab |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
70 + // The UID in the source buffer is not necessarily null terminated. Copy with memcpy |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
71 + // and add a zero byte. We have already checked that there is enough data available |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
72 + // in the source source buffer and enough space in the target buffer. |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
73 + (void) memcpy(role->SOPClassUID, buf, UIDLength); |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
74 + role->SOPClassUID[UIDLength] = '\0'; |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
75 + |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
76 buf += UIDLength; |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
77 role->SCURole = *buf++; |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
78 role->SCPRole = *buf++; |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
79 diff -urEb dcmtk-3.6.5.orig/oflog/include/dcmtk/oflog/thread/syncpub.h dcmtk-3.6.5/oflog/include/dcmtk/oflog/thread/syncpub.h |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
80 --- dcmtk-3.6.5.orig/oflog/include/dcmtk/oflog/thread/syncpub.h 2020-11-04 18:27:08.980662125 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
81 +++ dcmtk-3.6.5/oflog/include/dcmtk/oflog/thread/syncpub.h 2020-11-04 18:27:48.232609773 +0100 |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
82 @@ -63,7 +63,7 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
83 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
84 DCMTK_LOG4CPLUS_INLINE_EXPORT |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
85 Mutex::Mutex (Mutex::Type t) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
86 - : mtx (DCMTK_LOG4CPLUS_THREADED (new impl::Mutex (t)) + 0) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
87 + : mtx (DCMTK_LOG4CPLUS_THREADED (new impl::Mutex (t))) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
88 { } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
89 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
90 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
91 @@ -106,7 +106,7 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
92 DCMTK_LOG4CPLUS_INLINE_EXPORT |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
93 Semaphore::Semaphore (unsigned DCMTK_LOG4CPLUS_THREADED (max), |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
94 unsigned DCMTK_LOG4CPLUS_THREADED (initial)) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
95 - : sem (DCMTK_LOG4CPLUS_THREADED (new impl::Semaphore (max, initial)) + 0) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
96 + : sem (DCMTK_LOG4CPLUS_THREADED (new impl::Semaphore (max, initial))) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
97 { } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
98 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
99 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
100 @@ -148,7 +148,7 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
101 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
102 DCMTK_LOG4CPLUS_INLINE_EXPORT |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
103 FairMutex::FairMutex () |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
104 - : mtx (DCMTK_LOG4CPLUS_THREADED (new impl::FairMutex) + 0) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
105 + : mtx (DCMTK_LOG4CPLUS_THREADED (new impl::FairMutex)) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
106 { } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
107 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
108 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
109 @@ -190,7 +190,7 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
110 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
111 DCMTK_LOG4CPLUS_INLINE_EXPORT |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
112 ManualResetEvent::ManualResetEvent (bool DCMTK_LOG4CPLUS_THREADED (sig)) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
113 - : ev (DCMTK_LOG4CPLUS_THREADED (new impl::ManualResetEvent (sig)) + 0) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
114 + : ev (DCMTK_LOG4CPLUS_THREADED (new impl::ManualResetEvent (sig))) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
115 { } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
116 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
117 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
118 @@ -252,7 +252,7 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
119 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
120 DCMTK_LOG4CPLUS_INLINE_EXPORT |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
121 SharedMutex::SharedMutex () |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
122 - : sm (DCMTK_LOG4CPLUS_THREADED (new impl::SharedMutex) + 0) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
123 + : sm (DCMTK_LOG4CPLUS_THREADED (new impl::SharedMutex)) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
124 { } |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
125 |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
126 |
3722
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
127 diff -urEb dcmtk-3.6.5.orig/oflog/libsrc/oflog.cc dcmtk-3.6.5/oflog/libsrc/oflog.cc |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
128 --- dcmtk-3.6.5.orig/oflog/libsrc/oflog.cc 2020-11-04 18:27:08.984662119 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
129 +++ dcmtk-3.6.5/oflog/libsrc/oflog.cc 2020-11-04 18:27:48.232609773 +0100 |
3778 | 130 @@ -19,6 +19,10 @@ |
3722
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
131 * |
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
132 */ |
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
133 |
3775 | 134 +#if defined(_WIN32) |
3778 | 135 +# include <winsock2.h> |
3722
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
136 +#endif |
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
137 + |
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
138 #include "dcmtk/config/osconfig.h" /* make sure OS specific configuration is included first */ |
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
139 #include "dcmtk/oflog/oflog.h" |
a49d49d945c9
fixing openssl compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
3719
diff
changeset
|
140 |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
141 diff -urEb dcmtk-3.6.5.orig/ofstd/include/dcmtk/ofstd/offile.h dcmtk-3.6.5/ofstd/include/dcmtk/ofstd/offile.h |
4289
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
142 --- dcmtk-3.6.5.orig/ofstd/include/dcmtk/ofstd/offile.h 2020-11-04 18:27:09.008662088 +0100 |
dd17d37ad950
backporting a patch for DCMTK 3.6.5 to resolve a bad memory access in C-GET SCP
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4044
diff
changeset
|
143 +++ dcmtk-3.6.5/ofstd/include/dcmtk/ofstd/offile.h 2020-11-04 18:27:48.232609773 +0100 |
3719
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
144 @@ -575,7 +575,7 @@ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
145 */ |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
146 void setlinebuf() |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
147 { |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
148 -#if defined(_WIN32) || defined(__hpux) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
149 +#if defined(_WIN32) || defined(__hpux) || defined(__LSB_VERSION__) |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
150 this->setvbuf(NULL, _IOLBF, 0); |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
151 #else |
d737173197e1
upgraded DCMTK to 3.6.5
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
152 :: setlinebuf(file_); |