The Samba-Bugzilla – Attachment 3332 Details for
Bug 5515
All input fields in SWAT are empty
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Fix-empty-input-fields-in-SWAT
0001-Fix-empty-input-fields-in-SWAT-5515.patch (text/plain), 1.10 KB, created by
Andreas Schneider
on 2008-06-03 08:21:13 UTC
(
hide
)
Description:
Fix-empty-input-fields-in-SWAT
Filename:
MIME Type:
Creator:
Andreas Schneider
Created:
2008-06-03 08:21:13 UTC
Size:
1.10 KB
patch
obsolete
>From cf0a8c45c1c9404cfc9006c003f88d2b4764c670 Mon Sep 17 00:00:00 2001 >From: Andreas Schneider <anschneider@suse.de> >Date: Tue, 3 Jun 2008 15:19:46 +0200 >Subject: [PATCH] Fix empty input fields in SWAT; [#5515]. > >--- > source/web/swat.c | 13 +++++++------ > 1 files changed, 7 insertions(+), 6 deletions(-) > >diff --git a/source/web/swat.c b/source/web/swat.c >index 6d8f4ca..9dbc14f 100644 >--- a/source/web/swat.c >+++ b/source/web/swat.c >@@ -86,26 +86,27 @@ static const char *fix_quotes(TALLOC_CTX *ctx, const char *str) > > /* Count the number of quotes. */ > newstring_len = 1; >- while (*str) { >- if ( *str == '\"') { >+ p = (char *) str; >+ while (*p) { >+ if ( *p == '\"') { > newstring_len += quote_len; > } else { > newstring_len++; > } >- ++str; >+ ++p; > } > newstring = TALLOC_ARRAY(ctx, char, newstring_len); >- if (!newstring) { >+ if (newstring == NULL) { > return ""; > } >+ > for (p = newstring; *str; str++) { >- if ( *str == '\"') { >+ if (*str == '\"') { > strncpy( p, """, quote_len); > p += quote_len; > } else { > *p++ = *str; > } >- ++str; > } > *p = '\0'; > return newstring; >-- >1.5.4.5 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 5515
:
3330
|
3332
|
3333