Re: Porting guide Samba 2.2.x - 3.0

2002-12-04 Thread Rainer Link
[follow-up myself .. :) ]



unfortunately I wasn't able to follow the 3.0 development nor this ML 
very closely. Does a porting guide from 2.2.x to 3.0 exist?

I've just discovered that the following code

void send_message(pstring msg) {
[..]
unix_to_dos(msg);

len = strlen(msg);

if (!cli_message_start(cli, remote_machine, username, grp_id)) {
DEBUG(0,(message start: %s, cli_errstr(cli)));
return;
}
[..]

I fixed it this way, it works with Samba 3.0 alpha21, but probably not 
the best way :)
[..]
#if SAMBA_VERSION_MAJOR==3
fstrcpy(remote_machine, get_remote_machine_name());
DEBUG(5, (remote machine is: %s\n, remote_machine));
#endif
[..]
#if SAMBA_VERSION_MAJOR==2
pstrcpy(msg_conv, unix_to_dos(msg));
#elif SAMBA_VERSION_MAJOR==3
push_ascii_pstring(msg_conv, msg);
#endif

Hm, still I have to figure out, how a newline has to be encoded 
correctly, as the winpop pane of Win98 shows text1|text2 instead of
text1
text2.

best regards,
Rainer Link





Porting guide Samba 2.2.x - 3.0

2002-11-28 Thread Rainer Link
Folks,

unfortunately I wasn't able to follow the 3.0 development nor this ML 
very closely. Does a porting guide from 2.2.x to 3.0 exist?

I've just discovered that the following code

void send_message(pstring msg) {
[..]
unix_to_dos(msg);

len = strlen(msg);

if (!cli_message_start(cli, remote_machine, username, grp_id)) {
DEBUG(0,(message start: %s, cli_errstr(cli)));
return;
}
[..]

does not compile anymore with Samba 3.0 alpha 20, as the unix_to_dos 
function seems to be removed. Any equivalent available?

Thanks!

best regards,
Rainer Link
OpenAntiVirus.org