Re: sndio: more cleanup + multiple devices support

2011-11-10 Thread Remco
On Wednesday 09 November 2011 22:39:44 Alexandre Ratchov wrote:
  sun, sun: or sun:0 for the device and all three of them will play
  sound.  I'd expect only sun:0 to work.

 I agree, the number is mandatory.


Sorry for sending a patch on top of my previous patch but is something like 
this acceptable ? Seems to work after some very brief testing.

In case of sun use (len+1) to check for the colon and check if there's 
actual data after the colon:

--- sio.c.new   Wed Nov  9 14:09:44 2011
+++ sio.c   Thu Nov 10 12:42:28 2011
@@ -80,7 +80,7 @@
sio_is_type(str, len, aucat))
return sio_aucat_open(str + len, mode, nbio);
if (sio_is_type(str, len, rsnd) ||
-   sio_is_type(str, len, sun))
+   (sio_is_type(str, len+1, sun:)  str[len+1] != '\0'))
return sio_sun_open(str + len, mode, nbio);
DPRINTF(sio_open: %s: unknown device type\n, str);
return NULL;



Alaturati-va comunitatii online de Escorte / Inregistreaza-te gratuit

2011-11-10 Thread Escorte Dollhouse
Alaturati-va comunitatii online de Escorte

Escorte Independente Agentii Escorte Matrimoniale Masaj Erotic

Inregistreaza-te gratuit AICI si POTI adauga anunturi matrimoniale sau
intalniri cu scop erotic



In conformitate cu legea 365/2002 privind comertul electronic, acest
mesaj nu este si nu poate fi considerat spam, deoarece contine datele
noastre de identificare si optiunea de dezabonare, acceptarea de primire
a ofertei nu va implica financiar. V-a fost oferit datorita unuia dintre
urmatoarele motive: sunteti in baza noastra de date ca urmare a unor
corespondente anterioare, ati solicitat primirea ofertei noastre, adresa
Dvs. a fost selectata dintr-o baza de date la care ati subscris, adresa
dvs a fost facuta publica prin afisari cu caracter publicitar. Acest
mesaj va este adresat cu scopul de a va invita sa beneficiati de
serviciile companiei noastre si va este transmis in dorinta de a va tine
la curent cu cele mai noi si mai profitabile servicii pe care vi le putem
oferi. Pentru ca intelegem si apreciem dorinta dumneavoastra de
intimitate, ne cerem scuze daca acest mesaj a ajuns din greseala la dvs,
iar daca doriti sa nu mai primiti astfel de mesaje in viitor va rugam sa
urmariti indicatiile din josul paginii pentru Dezabonare (Unsubscribe).
Daca vi s-au parut interesante ofertele noastre le puteti trimite unui
prieten folosind legatura Forward email. Va multumim pentru intelegere!
Pentru dezabonare trimite-ti un email cu subiectul Dezabonare.



relayd doesn't send User-Agent string for HTTP 1.1 requests

2011-11-10 Thread Seth Wright
I was testing relayd a while back against a couple of IIS 7.5 servers
serving Exchange 2010.  It looks like IIS 7.5 (included with Windows 2008
R2) really wants HTTP 1.1 requests to include the User-Agent header in the
request; leaving it out generates a 400 Bad Request response.

The HTTP 1.1 spec[1] says of the User-Agent header, User agents SHOULD
include this field with requests.  Not a MUST, so maybe Microsoft is doing
it wrong by seemingly requiring it.  But since it's a SHOULD, perhaps relayd
should be sending it anyway for HTTP 1.1 requests?  Either way, it's a quick
fix and makes my relay check statements work:

Index: parse.y
===
RCS file: /cvs/src/usr.sbin/relayd/parse.y,v
retrieving revision 1.159
diff -u -p -r1.159 parse.y
--- parse.y 21 Sep 2011 18:45:40 -  1.159
+++ parse.y 10 Nov 2011 16:53:20 -
@@ -228,7 +228,7 @@ hostname: /* empty */   {
fatal(calloc);
}
| HOST STRING   {
-   if (asprintf($$, Host: %s\r\nConnection: close\r\n,
+   if (asprintf($$, Host: %s\r\nUser-Agent: 
relayd\r\nConnection: close\r\n,
$2) == -1)
fatal(asprintf);
}



Is this useful?

[1] http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.43

--
Seth



Hotel Tanti Spa Resort ::: NOVIEMBRE DE REGALO 2, 4 Y 6 NOCHES ::: Disfrute de las sierras de Córdoba :::

2011-11-10 Thread Marketing
No puedes visualizar las imagenes? Versisn Online

NOVIEMBRE DE REGALO
Sierras de Csrdoba - Tanti

[IMAGE]

[IMAGE]

[IMAGE]

[IMAGE]

!!!PROMOCISN 2, 4 Y 6 NOCHES!!!
Incluye media pensisn (Desayuno y Cena)

Noviembre 2, 4 y 6 Noches (Media Pensisn)

Esta promo incluye

Habitaciones

2Noches

4Noches

6Noches

Hab.Doble
Hab.Triple
Hab.Cuadruple
Hab.Quintuple

$860
$1140
$1320
$1500

$1640
$2160
$2510
$2860

$2340
$3090
$3590
$4090

; Acceso a minipiscina climatizada cubierta
; Acceso a piscina al aire libre
; Cochera cubierta (media sombra)

NO INCLUYE SERVICIOS DE SPA

Importante: Tarifas por habitacisn

Promocisn no valida
para fines de semana largo

Se aceptan tarjetas de cridito Visa MasterCard y American Express

Se aceptan tarjetas de cridito Visa MasterCard y American Express

Gral Paz 115 Tanti, Provincia de Csrdoba, Argentina
Tel : (03541)49-7195 / 49-7196
Reservas: consul...@hotel-tanti.com.ar  reser...@hotel-tanti.com.ar

Nuestra area de spa

!AVISO MUY IMPORTANTE!
SI VIAJA EN AUTO, !!!NO OLVIDE!!! LAS RUTAS Y AUTOPISTAS TIENEN RADARES.
ENCIENDA LAS LUCES BAJAS Y UTILICE CINTURONES DELANTEROS Y TRASEROS.

En caso de no querer recibir mas estas comunicaciones, responda este
correo con asunto REMOVER.



mmap diff for patch(1)

2011-11-10 Thread Michael W. Bombardieri
Hi tech,

I have a diff for the patch(1) tool which copies
one included in NetBSD two years ago...

Source: NetBSD src/usr.bin/patch/inp.c revision 1.23
Purpose: Don't bother mmap'ing an empty file

Comments/OK?

- Michael


Index: inp.c
===
RCS file: /usr/src/cvs/src/usr.bin/patch/inp.c,v
retrieving revision 1.35
diff -u -r1.35 inp.c
--- inp.c   27 Oct 2009 23:59:41 -  1.35
+++ inp.c   11 Nov 2011 03:12:10 -
@@ -243,12 +243,16 @@
if ((ifd = open(filename, O_RDONLY))  0)
pfatal(can't open file %s, filename);
 
-   i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0);
-   if (i_womp == MAP_FAILED) {
-   perror(mmap failed);
+   if (i_size == 0)
i_womp = NULL;
-   close(ifd);
-   return false;
+   else {
+   i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0);
+   if (i_womp == MAP_FAILED) {
+   perror(mmap failed);
+   i_womp = NULL;
+   close(ifd);
+   return false;
+   }
}
 
close(ifd);



Re: mmap diff for patch(1)

2011-11-10 Thread Abel Abraham Camarillo Ojeda
On Thu, Nov 10, 2011 at 9:26 PM, Michael W. Bombardieri m...@ii.net wrote:
 Hi tech,

 I have a diff for the patch(1) tool which copies
 one included in NetBSD two years ago...

 Source: NetBSD src/usr.bin/patch/inp.c revision 1.23
 Purpose: Don't bother mmap'ing an empty file

 Comments/OK?

 - Michael


 Index: inp.c
 ===
 RCS file: /usr/src/cvs/src/usr.bin/patch/inp.c,v
 retrieving revision 1.35
 diff -u -r1.35 inp.c
 --- inp.c B  B  B  27 Oct 2009 23:59:41 - B  B  B 1.35
 +++ inp.c B  B  B  11 Nov 2011 03:12:10 -
 @@ -243,12 +243,16 @@
 B  B  B  B if ((ifd = open(filename, O_RDONLY))  0)
 B  B  B  B  B  B  B  B pfatal(can't open file %s, filename);

 - B  B  B  i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0);
 - B  B  B  if (i_womp == MAP_FAILED) {
 - B  B  B  B  B  B  B  perror(mmap failed);
 + B  B  B  if (i_size == 0)
 B  B  B  B  B  B  B  B i_womp = NULL;
 - B  B  B  B  B  B  B  close(ifd);
 - B  B  B  B  B  B  B  return false;
 + B  B  B  else {
 + B  B  B  B  B  B  B  i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, 
 ifd, 0);
 + B  B  B  B  B  B  B  if (i_womp == MAP_FAILED) {
 + B  B  B  B  B  B  B  B  B  B  B  perror(mmap failed);
 + B  B  B  B  B  B  B  B  B  B  B  i_womp = NULL;
 + B  B  B  B  B  B  B  B  B  B  B  close(ifd);
 + B  B  B  B  B  B  B  B  B  B  B  return false;
 + B  B  B  B  B  B  B  }
 B  B  B  B }

 B  B  B  B close(ifd);



if if (i_size == 0) {...} returns, there's still need for an else block?...

Just asking...



Re: mmap diff for patch(1)

2011-11-10 Thread Michael W. Bombardieri
On Thu, Nov 10, 2011 at 11:10:34PM -0600, Abel Abraham Camarillo Ojeda wrote:
 On Thu, Nov 10, 2011 at 9:26 PM, Michael W. Bombardieri m...@ii.net wrote:
  Hi tech,
 
  I have a diff for the patch(1) tool which copies
  one included in NetBSD two years ago...
 
  Source: NetBSD src/usr.bin/patch/inp.c revision 1.23
  Purpose: Don't bother mmap'ing an empty file
 
  Comments/OK?
 
  - Michael
 
 
  Index: inp.c
  ===
  RCS file: /usr/src/cvs/src/usr.bin/patch/inp.c,v
  retrieving revision 1.35
  diff -u -r1.35 inp.c
  --- inp.c ?? ?? ?? 27 Oct 2009 23:59:41 - ?? ?? ??1.35
  +++ inp.c ?? ?? ?? 11 Nov 2011 03:12:10 -
  @@ -243,12 +243,16 @@
  ?? ?? ?? ??if ((ifd = open(filename, O_RDONLY))  0)
  ?? ?? ?? ?? ?? ?? ?? ??pfatal(can't open file %s, filename);
 
  - ?? ?? ?? i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0);
  - ?? ?? ?? if (i_womp == MAP_FAILED) {
  - ?? ?? ?? ?? ?? ?? ?? perror(mmap failed);
  + ?? ?? ?? if (i_size == 0)
  ?? ?? ?? ?? ?? ?? ?? ??i_womp = NULL;
  - ?? ?? ?? ?? ?? ?? ?? close(ifd);
  - ?? ?? ?? ?? ?? ?? ?? return false;
  + ?? ?? ?? else {
  + ?? ?? ?? ?? ?? ?? ?? i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, 
  ifd, 0);
  + ?? ?? ?? ?? ?? ?? ?? if (i_womp == MAP_FAILED) {
  + ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? perror(mmap failed);
  + ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? i_womp = NULL;
  + ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? close(ifd);
  + ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? ?? return false;
  + ?? ?? ?? ?? ?? ?? ?? }
  ?? ?? ?? ??}
 
  ?? ?? ?? ??close(ifd);
 
 
 
 if if (i_size == 0) {...} returns, there's still need for an else block?...
 
 Just asking...

Thanks for your comment.

From what I can see, plan_a() should return true in any case when we get
an empty file, so it should be fairly safe to return directly here as
you mentioned.

I have tested the following diff on i386; it appears to produce the same
behaviour as my previous diff. If this works for you, I'm happy to go
with the simpler diff rather than blindly following the NetBSD code.

- Michael


Index: inp.c
===
RCS file: /usr/src/cvs/src/usr.bin/patch/inp.c,v
retrieving revision 1.35
diff -u -r1.35 inp.c
--- inp.c   27 Oct 2009 23:59:41 -  1.35
+++ inp.c   11 Nov 2011 05:27:41 -
@@ -243,6 +243,8 @@
if ((ifd = open(filename, O_RDONLY))  0)
pfatal(can't open file %s, filename);
 
+   if (i_size == 0)
+   return true;
i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0);
if (i_womp == MAP_FAILED) {
perror(mmap failed);



Re: mmap diff for patch(1)

2011-11-10 Thread Michael W. Bombardieri
Sorry, let me try that again... Forgot to clean up file descriptor ifd.


Index: inp.c
===
RCS file: /usr/src/cvs/src/usr.bin/patch/inp.c,v
retrieving revision 1.35
diff -u -r1.35 inp.c
--- inp.c   27 Oct 2009 23:59:41 -  1.35
+++ inp.c   11 Nov 2011 06:51:13 -
@@ -243,6 +243,10 @@
if ((ifd = open(filename, O_RDONLY))  0)
pfatal(can't open file %s, filename);
 
+   if (i_size == 0) {
+   close(ifd);
+   return true;
+   }
i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0);
if (i_womp == MAP_FAILED) {
perror(mmap failed);