Details Ticket 2391


Comment | Reply | Take | Resolve


Serial Number 2391
Subject r.patch: creating support files fails when 1st map isn't local
Area bug
Queue grass
Requestors hamish_nospam@yahoo.com
Owner none
Status open
Last User Contact Tue Apr 27 16:30:23 2004 (4 yr ago)
Current Priority 30
Final Priority 70
Due No date assigned
Last Action Tue Apr 27 16:30:23 2004 (4 yr ago)
Created Tue Apr 27 07:11:31 2004 (4 yr ago)

Transaction History Ticket 2391


Tue, Apr 27 2004 07:11:31    Request created by hbowman  
Subject: r.patch: creating support files fails when 1st map isn't local

When running r.patch with "input=aspect@first_mapset,aspect@second_mapset",
building support files fails with the following errors:

r.patch: percent complete:  100%
CREATING SUPPORT FILES FOR aspect
WARNING: unable to find [aspect] in [(null)]
WARNING: category support for [aspect] in mapset [(null)] missing



grass/src/raster/r.patch/cmd/support.c header:
/*
 * creates new category and color structures from the patching
 * files category and color files
 *
 * the first patch file is used as the basis. Its cats and colr
 * are read into the final cats/colr structures.
 * Then the other patching layers cats/colr are added to the
 * final cats/colr only if these patching layers actually
 * contributed new categories to the final result
 */


thanks,
Hamish
Tue, Apr 27 2004 16:30:23    Mail sent by glynn.clements@virgin.net  
Return-Path <glynn.clements@virgin.net>
Delivered-To grass-bugs@lists.intevation.de
From Glynn Clements <glynn.clements@virgin.net>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Message-ID <16526.27179.548402.842389@cerise.nosuchdomain.co.uk>
Date Tue, 27 Apr 2004 15:11:55 +0100
To Request Tracker <grass-bugs@intevation.de>
Cc grass5@grass.itc.it
Subject Re: [GRASS5] [bug #2391] (grass) r.patch: creating support files fails when 1st map isn't local
In-Reply-To <20040427051131.AAE1D13B82@lists.intevation.de>
References <20040427051131.AAE1D13B82@lists.intevation.de>
X-Mailer VM 7.07 under 21.4 (patch 15) "Security Through Obscurity" XEmacs Lucid
X-Spam-Status No, hits=-4.9 tagged_above=-999.0 required=3.0 tests=BAYES_00
X-Spam-Level
Request Tracker wrote:

> Subject: r.patch: creating support files fails when 1st map isn't local
> 
> When running r.patch with "input=aspect@first_mapset,aspect@second_mapset",
> building support files fails with the following errors:
> 
> r.patch: percent complete:  100%
> CREATING SUPPORT FILES FOR aspect
> WARNING: unable to find [aspect] in [(null)]
> WARNING: category support for [aspect] in mapset [(null)] missing

main() calls G_raster_map_type(), which calls G_find_cell(), which
overwrites the qualified name with the unqualified version. The
unqualified names are then passed to the support() function.

Personally, I don't think that G_raster_map_type() ought to behave
like this. If someone was willing to check that none of the code which
calls it relies upon this behaviour, we could change it to use
G_find_cell2() instead.

More generally, we should eliminate the use of G_find_file in library
functions (other than G_find_cell etc). I suspect that this problem
isn't limited to r.patch.

But, so long as G_raster_map_type() has its current behaviour, the
only solution is to duplicate the elements of opt1->answers so that
the original values are available to support().

-- 
Glynn Clements <glynn.clements@virgin.net>


Comment | Reply | Take | Resolve

You are currently authenticated as guest.
[Show Configuration] [Login as another user]

Users Guide - Mail Commands - Homepage of RequestTracker 1.0.7 - list any request