1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-30 00:20:08 +00:00

bitbake/codeparser: fix raising of ShellSyntaxError

To raise the ShellSyntaxError we need to import it's module and reference it
by namespace.

Signed-off-by: Joshua Lock <josh@linux.intel.com>
This commit is contained in:
Joshua Lock
2011-02-25 10:22:44 +00:00
committed by Richard Purdie
parent 0b17cbc8f2
commit 92d5e6c07f
+2 -2
View File
@@ -4,7 +4,7 @@ import logging
import os.path
import bb.utils, bb.data
from itertools import chain
from pysh import pyshyacc, pyshlex
from pysh import pyshyacc, pyshlex, sherrors
logger = logging.getLogger('BitBake.CodeParser')
@@ -227,7 +227,7 @@ class ShellParser():
try:
tokens, _ = pyshyacc.parse(value, eof=True, debug=False)
except pyshlex.NeedMore:
raise ShellSyntaxError("Unexpected EOF")
raise sherrors.ShellSyntaxError("Unexpected EOF")
for token in tokens:
self.process_tokens(token)