serviceBatchMgr.sh creates file named "1" in current directory

Project:Kaltura Community Edition (CE) - Self Hosted Online Video Platform
Version:api_v3
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

Bug:

app/scripts/serviceBatchMgr.sh creates a file named "1" in the current directory. If there is a file named "1" in the current directory, and this file is not writable, the service stop routine fails.

Possible solution:

Patch app/scripts/serviceBatchMgr.sh:

stop() {
        echo -n $"Shutting down:"
        KP=$(pgrep -P 1 -f $FILE_NAME.php)
        if [ $KP > 1 ]; then

to

stop() {
        echo -n $"Shutting down:"
        KP=$(pgrep -P 1 -f $FILE_NAME.php)
        if [ "X$KP" != "X" ]; then