Review Request 106236: Custom buildsystem: avoid error if first command arg contains equals sign

Albert Astals Cid aacid at kde.org
Thu Feb 7 21:29:19 UTC 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106236/#review26905
-----------------------------------------------------------


I see this has a ship it but marked as uncommited. Was it commited and you forgot to close the request or is still uncommited?

- Albert Astals Cid


On Aug. 27, 2012, 7:13 p.m., Nicolas Alvarez wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/106236/
> -----------------------------------------------------------
> 
> (Updated Aug. 27, 2012, 7:13 p.m.)
> 
> 
> Review request for KDevelop and Andreas Pakulat.
> 
> 
> Description
> -------
> 
> Avoid error if the first argument to the build command contains an equals sign.
> 
> splitArgs with AbortOnMeta will return a FoundMeta error if the first word contains an equals sign, because it thinks it's a shell variable assignment, as in "LANG=C make" or similar. We were passing the list of arguments of the build command to KShell::splitArgs, without including the command itself. Thus, if the first argument (*after* the command name!) had an equals sign, like in command="make" arguments="V=1", KDevelop was saying "the given arguments would need a real shell", which isn't true.
> 
> This patch fixes the problem by passing the command name to splitArgs too (and then removing the command name from the returned split list).
> 
> 
> Diffs
> -----
> 
>   projectmanagers/custom-buildsystem/custombuildjob.cpp 83af2561c149fb8c807c8c4d58371f0b727e18f5 
> 
> Diff: http://git.reviewboard.kde.org/r/106236/diff/
> 
> 
> Testing
> -------
> 
> I didn't even test if it compiles. I just wanted to post the patch and run to class :)
> 
> 
> Thanks,
> 
> Nicolas Alvarez
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20130207/4456bf2d/attachment-0001.html>


More information about the KDevelop-devel mailing list