Bläddra i källkod

fix for layer > 1

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@36413 15284696-431f-4ddb-bdfa-cd5b030d7da7
Markus Neteler 16 år sedan
förälder
incheckning
2cb14caa4b
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      scripts/v.colors/v.colors

+ 1 - 1
scripts/v.colors/v.colors

@@ -209,7 +209,7 @@ fi
 #g.message "column <$GIS_OPT_COLUMN> is type [$NCOLUMN_TYPE]"
 
 # check if GRASSRGB column exists, make it if it doesn't
-TABLE=`v.db.connect -g map="$GIS_OPT_MAP" layer="$GIS_OPT_LAYER" fs=";" | cut -f2 -d';'`
+TABLE=`v.db.connect -g map="$GIS_OPT_MAP" layer="$GIS_OPT_LAYER" fs=";" | grep "^$GIS_OPT_LAYER;" | cut -f2 -d';'`
 COLUMN_TYPE=`v.info -c map="$GIS_OPT_MAP" layer="$GIS_OPT_LAYER" | grep -i "|$GIS_OPT_RGB_COLUMN$" | cut -f1 -d'|'`
 if [ -z "$COLUMN_TYPE" ] ; then
     # RGB Column not found, create it