Commit graph

15 commits

Author SHA1 Message Date
Nobuyoshi Nakada
8c3a60df2a
leakchecker.rb: show test name
When multiple autoclose IO objects are leaked too.
2020-05-16 17:35:09 +09:00
Kazuhiro NISHIYAMA
22b1e824d7
Check encodings of STDIN,STDOUT,STDERR too 2020-05-08 00:12:48 +09:00
Nobuyoshi Nakada
545d2ab7d2
leakchecker.rb: try lsof 2020-05-07 02:58:28 +09:00
Nobuyoshi Nakada
de3f725978
Makes nil-safe 2020-05-06 14:09:03 +09:00
Nobuyoshi Nakada
b247ac086e
Ignore FDs kept by system library
`getaddrinfo` on macOS seems keeping FDs to query host names
internally.
2020-05-06 13:47:09 +09:00
Nobuyoshi Nakada
039a8ef786
leakchecker.rb: search /dev/fd too
It is more popular than /proc/self/fd.
2020-05-06 10:09:29 +09:00
Koichi Sasada
cf52f37cae Narrow the check target.
Call GC.verify_internal_consistency only for Gem related test
on i386-solaris.
2020-03-04 11:25:43 +09:00
Yusuke Endoh
43ed4eb6d1 Limit the debug code conditon so that it runs only under i386-solaris 2020-03-03 21:00:03 +09:00
Koichi Sasada
1ad9364440 add debug code for Solaris
Check heap consistency after each test to debug.
20200303T012406Z.fail.html.gz
2020-03-03 15:53:46 +09:00
Kazuhiro NISHIYAMA
729b7ce270
Add check_warning_flags to leakchecker 2019-12-27 13:06:31 +09:00
Jeremy Evans
c5c05460ac Warn on access/modify of $SAFE, and remove effects of modifying $SAFE
This removes the security features added by $SAFE = 1, and warns for access
or modification of $SAFE from Ruby-level, as well as warning when calling
all public C functions related to $SAFE.

This modifies some internal functions that took a safe level argument
to no longer take the argument.

rb_require_safe now warns, rb_require_string has been added as a
version that takes a VALUE and does not warn.

One public C function that still takes a safe level argument and that
this doesn't warn for is rb_eval_cmd.  We may want to consider
adding an alternative method that does not take a safe level argument,
and warn for rb_eval_cmd.
2019-11-18 01:00:25 +02:00
Yusuke Endoh
c02de30efb tool/lib/leakchecker.rb: show the code location that allocated leaked fd
by using ObjectSpace.trace_object_allocations.

`make test-all LEAK_CHECKER_TRACE_OBJECT_ALLOCATION=true` will print not
only leaked fds but also where it was created.
2019-11-12 01:47:18 +09:00
Koichi Sasada
945560008f Revert "introduce debug check."
This reverts commit c3b84f2de8.
Backtrace shows it is before running tests and debug check was
nonsense.
2019-09-30 17:59:10 +09:00
Koichi Sasada
c3b84f2de8 introduce debug check.
There are random failures:

> lib/rubygems/core_ext/kernel_require.rb:61:in `require':
> wrong number of arguments (given 1, expected 0) (ArgumentError)
http://ci.rvm.jp/results/trunk-jemalloc@silicon-docker/2275159

To check this failure, I added a small check code.
2019-09-30 17:23:36 +09:00
Hiroshi SHIBATA
c3c0e3f5c9 Move to tool/lib from test/lib. 2019-07-02 07:59:54 +09:00
Renamed from test/lib/leakchecker.rb (Browse further)