/[winpt]/trunk/MyGPGME/gpgme.c
ViewVC logotype

Diff of /trunk/MyGPGME/gpgme.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 6 by twoaday, Mon Jan 31 11:02:21 2005 UTC revision 7 by twoaday, Mon Apr 4 07:01:43 2005 UTC
# Line 181  gpgme_set_comment (gpgme_ctx_t c, const Line 181  gpgme_set_comment (gpgme_ctx_t c, const
181          return;          return;
182      safe_free (c->comment);      safe_free (c->comment);
183      c->comment = strdup (text);      c->comment = strdup (text);
184        if (!c->comment)
185            c->out_of_core = 1;
186    }
187    
188    
189    void
190    gpgme_set_homedir (gpgme_ctx_t c, const char *homedir)
191    {
192        if (!c)
193            return;
194        safe_free (c->homedir);
195        c->homedir = strdup (homedir);
196        if (!c->homedir)
197            c->out_of_core = 1;
198  }  }
199    
200    
# Line 423  _gpgme_get_tmpfile( int input ) Line 437  _gpgme_get_tmpfile( int input )
437    
438      GetTempPath( sizeof path -1, path );      GetTempPath( sizeof path -1, path );
439      _snprintf( tmpfile, sizeof tmpfile -1,      _snprintf( tmpfile, sizeof tmpfile -1,
440          "%sgpgme%s.%u", path, input? "IN" : "OUT", _getpid() );          "%sgpgme%s.%u", path, input? "IN" : "OUT", getpid() );
441      return tmpfile;      return tmpfile;
442  } /* _gpgme_get_tmpfile */  } /* _gpgme_get_tmpfile */
443    
# Line 438  _gpgme_unlink( const char * file, int ar Line 452  _gpgme_unlink( const char * file, int ar
452  void  void
453  _gpgme_del_tmpfiles( gpgme_wipe_t wipe_fnc )  _gpgme_del_tmpfiles( gpgme_wipe_t wipe_fnc )
454  {  {
455      gpgme_wipe_t erase = wipe_fnc? wipe_fnc: _gpgme_unlink;      gpgme_wipe_t erase = wipe_fnc? wipe_fnc: (gpgme_wipe_t)_gpgme_unlink;
456    
457      erase( _gpgme_get_tmpfile( 0 ), 1 );              erase( _gpgme_get_tmpfile( 0 ), 1 );        
458      erase( _gpgme_get_tmpfile( 1 ), 1 );      erase( _gpgme_get_tmpfile( 1 ), 1 );
# Line 494  _gpgme_progress_handler (gpgme_ctx_t ctx Line 508  _gpgme_progress_handler (gpgme_ctx_t ctx
508      /* XXX remove space at the end */      /* XXX remove space at the end */
509      i = 0;      i = 0;
510      buf = args + (p-args);      buf = args + (p-args);
511      while ((p = strsep (&buf, " "))) {      while ((p = strsep (&buf, " ")) != NULL) {
512          switch (i) {          switch (i) {
513          case 0:          case 0:
514              break; /* type */              break; /* type */
# Line 571  gpgme_lib_cleanup (void) Line 585  gpgme_lib_cleanup (void)
585      rungpg_cleanup ();      rungpg_cleanup ();
586      io_cleanup ();      io_cleanup ();
587      wait_cleanup ();      wait_cleanup ();
588        util_cleanup ();
589  }  }

Legend:
Removed from v.6  
changed lines
  Added in v.7

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26