lclint-interest message 71

From Wed Apr 24 14:52:49 1996
Date: Wed, 24 Apr 1996 14:16:18 -0400
From: Eric Bloodworth 
Organization: Recognition Research, Inc
X-Mailer: Mozilla 2.01 (X11; I; OSF1 V3.2 alpha)
Mime-Version: 1.0
To: lclint_sig 
Subject: sanity check...
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

I must be missing something here, or there's a bug..
 In the actual function, 
*name becomes a pointer somewhere into path, but this
fragment produces the same error.    

lclint.c:18,11: Unqualified storage *name corresponds to storage listed
                   post:dependent clause
  Dependent storage is transferred to a non-dependent reference. Use
  -dependenttrans to suppress message.   

extern int foobar(
	char *path, 
	/*@special@*/ char **name, 
	/*@special@*/ int *len) 
		/*@post:dependent *name@*/
		/*@pre:notnull name, len@*/
		/*@defines *name, *len@*/;

int foobar(char *path,char **name,int *len)

	*name = path; 
	*len = strlen(path); 

	return 0;  /* this is line 18 */

 -- Eric

Previous Message Next Message Archive Summary LCLint Home Page David Evans
University of Virginia, Computer Science