runrev/livecode — pull request #1551 by peter-b (2014-11-28 15:10:12+00:00)
Title: [[ Bug 13695 ]] MCU_fix_path: Correctly handle '..' as 2nd relpath component

MCU_fix_path() previously implemented the following transformations:

/../suffix --> /suffix [correct]
prefix/xxx/../suffix --> prefix/suffix [correct]
xxx/../suffix --> /suffix [incorrect]

This problem only occurred when the path component cancelled by a '..'
path component occurred as the first element in a relative path.

This patch corrects the handling by ensuring that when a second path
separator cannot be located before the '..' component, one is removed
from after it instead.