You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Garrett Rooney <ro...@electricjellyfish.net> on 2006/06/14 13:53:47 UTC

Re: svn commit: r20091 - branches/merge-tracking/subversion/libsvn_fs_fs

On 6/13/06, dberlin@tigris.org <db...@tigris.org> wrote:

>        st = svn_string_createf(pool,
> -                             "delete from mergeinfo_uuid where revision = %"
> +                             "delete from mergeinfo_changed where revision = %"
> +                             SVN_REVNUM_T_FMT ";", new_rev);
> +      SVN_ERR(fs_sqlite_exec(ftd->mtd, st->data, NULL, NULL));
> +      st = svn_string_createf(pool,
> +                             "delete from mergeinfo where revision = %"
>                               SVN_REVNUM_T_FMT ";", new_rev);
>        SVN_ERR(fs_sqlite_exec(ftd->mtd, st->data, NULL, NULL));

Any particular reason this stuff uses svn_string_t?  You don't seem to
actually use the length, so you might as well just use apr_psprintf
and generate char *s.

-garrett

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn commit: r20091 - branches/merge-tracking/subversion/libsvn_fs_fs

Posted by Daniel Berlin <db...@dberlin.org>.
Garrett Rooney wrote:
> On 6/13/06, dberlin@tigris.org <db...@tigris.org> wrote:
> 
>>        st = svn_string_createf(pool,
>> -                             "delete from mergeinfo_uuid where revision = %"
>> +                             "delete from mergeinfo_changed where revision = %"
>> +                             SVN_REVNUM_T_FMT ";", new_rev);
>> +      SVN_ERR(fs_sqlite_exec(ftd->mtd, st->data, NULL, NULL));
>> +      st = svn_string_createf(pool,
>> +                             "delete from mergeinfo where revision = %"
>>                               SVN_REVNUM_T_FMT ";", new_rev);
>>        SVN_ERR(fs_sqlite_exec(ftd->mtd, st->data, NULL, NULL));
> 
> Any particular reason this stuff uses svn_string_t? 

No.
I was trying to get something quickly for dlr to be able to test with,
and this was the first way to do that that popped into my head :)

I've fixed it now.

 You don't seem to
> actually use the length, so you might as well just use apr_psprintf
> and generate char *s.
> 
> -garrett
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org