bug-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: May be BUG


From: Veera Prasad
Subject: RE: May be BUG
Date: Thu, 4 Mar 2004 22:18:14 -0500

Thanks guys for your Help..

I 've found the stuff which I am hunting for since couple of weeks... 
Here I go with the diff's of commit.c file.

--- commit.1.12.5.c     2004-01-03 13:02:40.000000000 +0100
+++ commit.c    2004-01-07 18:18:48.000000000 +0100
@@ -1074,7 +1074,53 @@ precommit_list_proc (Node *p, void *clos
        || li->type == T_MODIFIED
        || li->type == T_REMOVED)
     {
-       run_arg (p->key);
+        
+        char *argBuf;
+        char *type_stat;
+        char *tag_stat;
+        char *rev_old;
+
+        type_stat="";
+        switch (li->type)
+        {
+        case T_ADDED:
+           type_stat="Add";
+           break;
+        case T_MODIFIED:
+           type_stat="Modify";
+           break;
+        case T_REMOVED:
+           type_stat="Remove";
+           break;
+        }
+        
+        if (li->tag==NULL 
+            || strlen(li->tag) == 0 )
+        { 
+           tag_stat="main"; 
+        }
+        else
+        { 
+           tag_stat=li->tag; 
+        }
+
+        if (li->rev_old==NULL 
+            || strlen(li->rev_old) == 0 )
+        { 
+           rev_old="0"; 
+        }
+        else
+        { 
+           rev_old=li->rev_old; 
+        }
+          
+               argBuf = xmalloc ( strlen(p->key) +
+                strlen(type_stat) +
+                strlen(tag_stat) +
+                strlen(rev_old) + 5);
+        sprintf(argBuf,"%s:%s:%s:%s",p->key,type_stat,tag_stat,rev_old);
+        run_arg (argBuf);
+        free(argBuf);
     }
     return (0);
 }


Regards
--NVP.



-----Original Message-----
From: address@hidden [mailto:address@hidden
Sent: Wednesday, March 03, 2004 11:27 AM
To: address@hidden
Cc: address@hidden
Subject: Re: May be BUG


Veera Prasad writes:
> 
> I am expecting to see like below:
> 
> Thanks for giving me 2 command-line arguments!
>  /opt/master/olf/sdb
>  commitinfo:mytest:MAINLINE:1.7

Why are you expecting that?  You're calling your script from commitprep
and those scripts, like it says right at the top of the file, get passed
the full path to the repository and a list of file *names* that are
involved.

-Larry Jones

I'm not a vegetarian!  I'm a dessertarian. -- Calvin


© 2003 OpenLink Financial 

Copyright in this message and any attachments remains with us.  It is
confidential and may be legally privileged.   If this message is not 
intended for you it must not be read, copied or used by you or 
disclosed to anyone else.   Please advise the sender immediately if 
you have received this message in error.

Although this message and any attachments are believed to be free of 
any virus or other defect that might affect any computer system into 
which it is received and opened, it is the responsibility of the 
recipient to ensure that it is virus free and no responsibility 
is accepted by Open Link Financial, Inc. for any loss or damage in any 
way arising from its use.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]