winevt_c 0.3.3-x86-mingw32 → 0.3.4-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '08a0f43cef62aad6e5d4b0af93dbb900d4f0db4c1c6988aa6c47180a65868544'
4
- data.tar.gz: '02907f6522776b4a7dc20d624806d74adc803fc7dcef64484cbc71ed26e5265d'
3
+ metadata.gz: 282bd49abbeea4edf6b5016004285f506b6aa9b99e44fdc76d950f921a6c5827
4
+ data.tar.gz: 6d039edbb350f67ef0cb4335a37a7931b9d8d15a8091ea2929859580d2445b92
5
5
  SHA512:
6
- metadata.gz: ea2b090beec056b28ce941fe25cc0fd77dce98924ccb57aca4a2922a7c9b2a1555eff1090d975ba8c9d725d21d2aac0dd040b95435abe7767db0953ac4b84f66
7
- data.tar.gz: 3993f346442e8c94edf1e331112b4002fa06529267db527b04ab4352292f63f38aad193e8d5f73934359800abb79766e2912b80c9d40f8ee43da167f25e433b9
6
+ metadata.gz: 4e738b35de5a950c1525aaf5334404500f73c06c2718dec04a2e6b5c6e78cad433d68a623c354cbfa4746bbf6a9428f26b9febada2c04cb68e8ac2a6aff1edc4
7
+ data.tar.gz: 4b64faab9db5237f0fee0d169bda02cc2c0d66250bebc172ce00b77231c616819dcb02a31931e1face4b9789d2b8ed318c35f70d60a9cdea5e2fd4967999dc39
@@ -59,7 +59,10 @@ char* render_event(EVT_HANDLE handle, DWORD flags)
59
59
  MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
60
60
  msgBuf, 0, NULL);
61
61
 
62
- rb_raise(rb_eWinevtQueryError, "ErrorCode: %d\nError: %s\n", status, msgBuf);
62
+ VALUE errmsg = rb_str_new2(msgBuf);
63
+ LocalFree(msgBuf);
64
+
65
+ rb_raise(rb_eWinevtQueryError, "ErrorCode: %d\nError: %s\n", status, RSTRING_PTR(errmsg));
63
66
  }
64
67
 
65
68
  result = wstr_to_mbstr(CP_UTF8, buffer, -1);
@@ -122,7 +125,10 @@ VALUE get_values(EVT_HANDLE handle)
122
125
  MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
123
126
  msgBuf, 0, NULL);
124
127
 
125
- rb_raise(rb_eWinevtQueryError, "ErrorCode: %d\nError: %s\n", status, msgBuf);
128
+ VALUE errmsg = rb_str_new2(msgBuf);
129
+ LocalFree(msgBuf);
130
+
131
+ rb_raise(rb_eWinevtQueryError, "ErrorCode: %d\nError: %s\n", status, RSTRING_PTR(errmsg));
126
132
  }
127
133
 
128
134
  PEVT_VARIANT pRenderedValues = (PEVT_VARIANT)buffer;
@@ -322,7 +328,10 @@ char* get_description(EVT_HANDLE handle)
322
328
  MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
323
329
  msgBuf, 0, NULL);
324
330
 
325
- rb_raise(rb_eWinevtQueryError, "ErrorCode: %d\nError: %s\n", status, msgBuf);
331
+ VALUE errmsg = rb_str_new2(msgBuf);
332
+ LocalFree(msgBuf);
333
+
334
+ rb_raise(rb_eWinevtQueryError, "ErrorCode: %d\nError: %s\n", status, RSTRING_PTR(errmsg));
326
335
  }
327
336
 
328
337
  // Obtain buffer as EVT_VARIANT pointer. To avoid ErrorCide 87 in EvtRender.
Binary file
Binary file
Binary file
@@ -1,3 +1,3 @@
1
1
  module Winevt
2
- VERSION = "0.3.3"
2
+ VERSION = "0.3.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: winevt_c
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.4
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - Hiroshi Hatake
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-06-24 00:00:00.000000000 Z
11
+ date: 2019-06-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler