Fixup fromcvs/togit conversion
[minix-pkgsrc.git] / misc / kdepim4 / patches / patch-al
blob127043a0b83e3d7e40cb7b408b98706d62ad2b4e
1 $NetBSD$
3 libassuan2 support from
4 http://websvn.kde.org/?view=revision&revision=1078528
6 --- kleopatra/tests/test_uiserver.cpp.orig      2009-07-17 21:45:43.000000000 +0000
7 +++ kleopatra/tests/test_uiserver.cpp
8 @@ -89,17 +89,17 @@ static void usage( const std::string & m
9      exit( 1 );
10  }
12 -static assuan_error_t data( void * void_ctx, const void * buffer, size_t len ) {
13 +static gpg_error_t data( void * void_ctx, const void * buffer, size_t len ) {
14      (void)void_ctx; (void)buffer; (void)len;
15      return 0; // ### implement me
16  }
18 -static assuan_error_t status( void * void_ctx, const char * line ) {
19 +static gpg_error_t status( void * void_ctx, const char * line ) {
20      (void)void_ctx; (void)line;
21      return 0;
22  }
24 -static assuan_error_t inquire( void * void_ctx, const char * keyword ) {
25 +static gpg_error_t inquire( void * void_ctx, const char * keyword ) {
26      assuan_context_t ctx = (assuan_context_t)void_ctx;
27      assert( ctx );
28      const std::map<std::string,std::string>::const_iterator it = inquireData.find( keyword );
29 @@ -121,7 +121,7 @@ int main( int argc, char * argv[] ) {
31      const Kleo::WSAStarter _wsastarter;
33 -    assuan_set_assuan_err_source( GPG_ERR_SOURCE_DEFAULT );
34 +    assuan_set_gpg_err_source( GPG_ERR_SOURCE_DEFAULT );
36      if ( argc < 3 )
37          usage(); // need socket and command, at least
38 @@ -185,7 +185,12 @@ int main( int argc, char * argv[] ) {
40      assuan_context_t ctx = 0;
42 -    if ( const gpg_error_t err = assuan_socket_connect_ext( &ctx, socket, -1, ASSUAN_CONNECT_FLAGS ) ) {
43 +    if ( const gpg_error_t err = assuan_new( &ctx ) ) {
44 +        qDebug( "%s", Exception( err, "assuan_new" ).what() );
45 +        return 1;
46 +    }
48 +    if ( const gpg_error_t err = assuan_socket_connect( ctx, socket, -1, ASSUAN_CONNECT_FLAGS ) ) {
49          qDebug( "%s", Exception( err, "assuan_socket_connect_ext" ).what() );
50          return 1;
51      }
52 @@ -279,7 +284,7 @@ int main( int argc, char * argv[] ) {
53          return 1;
54      }
56 -    assuan_disconnect( ctx );
57 +    assuan_release( ctx );
59      return 0;
60  }