Age | Commit message (Collapse) | Author | Files | Lines |
|
On win32, a process is identified by a HANDLE, but for identifying
a running process we should use GetProcessId() to return a meaningful integer.
This means we need to be able to back and forth between a pid and a process handle
(phandle). We also need to be careful to get the pid before the process handle closes
since it isn't available afterwards.
Also call the handle to intptr_t for open_osfhandle() to avoid a compiler warning.
Fixes #217
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
In addition to "on codes ..."
it is now possible to trap on errorcode with
"trap sublist ..."
e.g.
try {
...
} trap CHILDSTATUS {msg opts} {
...
}
Fixes #204
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Fixes #215
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
This is the default already for newer versions of redis.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
There is no reason to allow a reference to contain leading and/or
trailing white space, so remove this check and simply treat
it as an invalid reference.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
oo.tcl returns globally qualified names like
::<reference.<tree___>.00000000000000000000>
So allow getref and setref to handle these qualified references
Fixes #218
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
It isn't used (always zero) and isn't needed.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Makes it easier to override
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Once we determine the number of pending bytes to read,
there is no need to read one at a time.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Detection of eof takes precedence over detection of error.
Fixes #207
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Previously calling gets on a non-blocking stream could easily
result in a partial line. Now if a partial line is read, return zero/empty
to indicate that nothing is available while storing the partial line.
The next call to gets (typically within a readable script) will continue
appending to the previous partial line until a complete line can be returned.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
So don't build it unless --shared is specified
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
In order for build-jim-ext to work against an uninstalled, shared libjim
we also need to create the unversioned symlink.
But not on Windows where we don't currently version the shared lib.
Fixes: #216
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Needs include, lib paths when jim is not installed
Fixes: #216
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
The command line processing was wrong such that 'file delete -force abc'
would also try to delete files named 'delete' and '-force' in the current directory.
If the current directory was writable, this would succeed, but it not writable
this would fail and so the desired target was not deleted.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Fixes #214
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
This issue was caused by the fix in 24b234543c7322d2dd20339b45367fa3f4c53495
Because we used closed hashing for the dict hash table, it is important
that the table doesn't get too full, as it gets very inefficient due to
hash collisions. When allowing for space, also consider dummy entries that
consume slots. If there are too many dummy slots, the hash table is expanded,
clearing out the dummy slots.
Without this fix it is possible to get unlucky when filling a dictionary
and emptying it again (twice) will result all slots become dummy slots
and thus no more entries can be added.
See REGTEST 54
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
The original jim_hello was a bad example that directly used
interpreter data members, so it was removed and jim_inline
became jim_hello.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Due to the way hash collisions are managed it is possible
to have a sequence where an entry is removed and then another
entry is replaced, however the replacement adds an additional
entry instead of updating the existing entry.
Can be reproduced like this as there is a hash collision between
these two keys:
dict set d 0,13 X
dict set d 8,4 Y
dict unset d 0,13
dict set d 8,4 Z
Should result in one entry in the dictionary, but instead ends with two.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
|
|
E.g., see the hourglass character U+231B closing the range at line 1111
of the bundled EastAsianWidth.txt:
https://github.com/msteveb/jimtcl/blob/3bf391ebe1a87c1fd0fc064254ef40976dff06f9/EastAsianWidth.txt#L1111
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Fixes: #210
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Fix the following build failure raised with openocd and autoconf >= 2.70
due to
http://git.savannah.gnu.org/gitweb/?p=autoconf.git;a=commit;h=aba75f6d4a9c875a9d5d90a07c6b3678db66a4bf:
>>> openocd 0.11.0 Autoreconfiguring
autoreconf: error: configure.ac: AC_INIT not found; not an autoconf script?
Fixes:
- http://autobuild.buildroot.org/results/5fb7aa28703aff61ba850eac11bd35c8804528ae
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
|
When extracting the results of a query, an integer result
should be retrieved with sqlite3_column_int64(), not sqlite3_column_int()
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
The name of the subcommand was inadvertently "lock ?-wait?" rather than "lock"
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Both for -commands and -help, and when an error is generated,
sort the subcommands.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
(This brings autosetup to v0.7.0-7-gc154c58)
Signed-off-by: Veronika Kremneva <kremneva@synopsys.com>
|
|
bootstrap jimsh doesn't have garbage collection, so move
such tests into ref.test
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
When a reference is used as a command name (e.g. in oo.tcl) it
is created in the global namespace as ::<reference...
The current check for references that are commands with a reference
count of 1 doesn't take this into account so these references
were not being garbage collected.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Don't try to dup2() a file descriptor that is already
correct. This can happen if, for example, stdin is closed
and exec redirects stdin from a file, thus opening the input
as file descriptor 0.
Fixes #201
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Quote the build dir or and the path to jimsh/tclsh
in the Makefile in case they contain spaces.
Also fix a few problems in tests/ that arise when the build
and/or source dir contain spaces.
Fixes #199
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
In case the path to configure contains spaces.
v0.7.0-6-g8e7e397
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Some users may not be ready to immediately move to the single-argument
expr, so provide a --compat option to configure to support the
previous behaviour as a transition strategy.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Use a single subencoder proc for all types.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Fixes #198
Reported-by: Antonio Borneo <borneo.antonio@gmail.com>
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Avoid unexpected issues by concatenating multiple arguments.
This does create an incompatibility with early versions, but
it is generally trivial to convert existing code to one of two forms:
1. expr {$a + $b} -- usually correct
2. expr "$a + $b" -- usually incorrect
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Some old systems are not happy with a numeric service and no socktype.
Fixes #196
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
In the case where interp is not supported
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|
|
In preparation for support of posix mode flags to open
Signed-off-by: Steve Bennett <steveb@workware.net.au>
|