home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / database / sybase / 610 < prev    next >
Encoding:
Text File  |  1993-01-06  |  2.4 KB  |  55 lines

  1. Newsgroups: comp.databases.sybase
  2. Path: sparky!uunet!s5!is1.is.morgan.com!is.morgan.com!shafla
  3. From: shafla@is.morgan.com (Sharon Flanagan)
  4. Subject: Open Server problem
  5. Message-ID: <1993Jan6.101709@is.morgan.com>
  6. Sender: news@is.morgan.com
  7. Nntp-Posting-Host: shafla
  8. Organization: Morgan Stanley - IS
  9. Date: Wed, 6 Jan 1993 15:17:09 GMT
  10. Lines: 43
  11.  
  12.  
  13. Hello,
  14.  
  15. BACKGROUND:
  16.  
  17. I'm working with a Sybase open server based on the "utility" sample program.
  18. I've written an RPC which allowes various clients to send and recieve
  19. information.  When a client registers for information, it sends the name of
  20. the RPC, a paramater that indicates it is a register message, its transaction
  21. type, and some parameters to hold the information it wants.  The function
  22. allocates space for a new srvproc, uses srv_bmove() to copy the srvproc and
  23. this new srvproc is then added to a linked list which is indexed by
  24. transaction type.  When a client notifies the open server that it has
  25. information, it sends the name of the RPC, a parameter that indicates that
  26. it is a notify message, its transaction type, and parameters which hold its
  27. information. The code goes through the linked list - if it finds a matching
  28. transaction type, it puts information from the current srvproc to a copy of the srvproc from the linked list.
  29.  
  30. PROBLEM:
  31. The forementioned program works with the first notify.  I use the
  32. srv_senddone() with the SRV_DONE_FINAL flag set when I return the information
  33. to the registering client.  However, when another client notifies that it
  34. has information, my program gets a SEGV error when it tries to find the number
  35. of parameters in the linked list srvproc.  The srv_senddone() function
  36. seems to clear out the parameters from the srvproc in the linked list -
  37. I've used a srv_rpcparams() call after the srv_senddone() and its result is
  38. -1 (perhaps no current RPC).  I've used srv_bmove to copy the srvproc from
  39. the linked list into another area of memory - but it didn't help.
  40.  
  41. How can I send information back to the clients multiple times over the open
  42. server - client connection?  Is there a way to circumvent the "flush" which
  43. happens with a srv_senddone?  If I use the SRV_DONE_MORE flag, the client
  44. doesn't get data.
  45. I've tested the open server using functions which login to it and then
  46. send information via the dbproc (dprpcparam(), dbrpcsend()).
  47.  
  48. Any ideas?????
  49.  
  50.  
  51. Thanks in advance for any assistance.
  52.  
  53. Sharon Flanagan
  54. shafla@is.morgan.com
  55.