pwsafe-0.2.0-XChangeProperty.patch 1.6 KB

1234567891011121314151617181920212223
  1. This patch came from <https://bugzilla.redhat.com/show_bug.cgi?id=667541>.
  2. Index: pwsafe.cpp
  3. ===================================================================
  4. RCS file: /cvsroot/pwsafe/pwsafe/pwsafe.cpp,v
  5. retrieving revision 1.57
  6. diff -u -r1.57 pwsafe.cpp
  7. --- pwsafe.cpp 12 Aug 2007 12:33:06 -0000 1.57
  8. +++ pwsafe.cpp 5 Jan 2011 22:16:43 -0000
  9. @@ -1820,10 +1820,10 @@
  10. if (xev.xselectionrequest.target == XA_TARGETS(xdisplay)) {
  11. // tell them what we can supply
  12. const Atom targets[] = { XA_TARGETS(xdisplay), XA_TIMESTAMP(xdisplay), XA_TEXT(xdisplay), XA_STRING };
  13. - XChangeProperty(xdisplay, xev.xselectionrequest.requestor, prop, XA_TARGETS(xdisplay), 32, PropModeReplace, reinterpret_cast<const unsigned char*>(&targets), sizeof(targets)/sizeof(targets[0]));
  14. + XChangeProperty(xdisplay, xev.xselectionrequest.requestor, prop, XA_ATOM, 32, PropModeReplace, reinterpret_cast<const unsigned char*>(&targets), sizeof(targets)/sizeof(targets[0]));
  15. }
  16. else if (xev.xselectionrequest.target == XA_TIMESTAMP(xdisplay)) {
  17. - XChangeProperty(xdisplay, xev.xselectionrequest.requestor, prop, XA_TIMESTAMP(xdisplay), 32, PropModeReplace, reinterpret_cast<const unsigned char*>(&timestamp), 1);
  18. + XChangeProperty(xdisplay, xev.xselectionrequest.requestor, prop, XA_INTEGER, 32, PropModeReplace, reinterpret_cast<const unsigned char*>(&timestamp), 1);
  19. }
  20. else if (xev.xselectionrequest.target == XA_TEXT(xdisplay) ||
  21. xev.xselectionrequest.target == XA_STRING) {