summaryrefslogtreecommitdiff
path: root/source3/printing/nt_printing.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2001-07-04 07:36:09 +0000
committerAndrew Tridgell <tridge@samba.org>2001-07-04 07:36:09 +0000
commit527e824293ee934ca5da0ef5424efe5ab7757248 (patch)
treedd86fab3b0ba9cdbd86661dfae562fa123a8f53c /source3/printing/nt_printing.c
parent87fbb7092b8f8b2f0db0f361c3d625e19de57cd9 (diff)
downloadsamba-527e824293ee934ca5da0ef5424efe5ab7757248.tar.gz
samba-527e824293ee934ca5da0ef5424efe5ab7757248.tar.bz2
samba-527e824293ee934ca5da0ef5424efe5ab7757248.zip
strchr and strrchr are macros when compiling with optimisation in gcc, so we can't redefine them. damn.
(This used to be commit c41fc06376d1a2b83690612304e85010b5e5f3cf)
Diffstat (limited to 'source3/printing/nt_printing.c')
-rw-r--r--source3/printing/nt_printing.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/source3/printing/nt_printing.c b/source3/printing/nt_printing.c
index d099c29cc1..d742773d27 100644
--- a/source3/printing/nt_printing.c
+++ b/source3/printing/nt_printing.c
@@ -673,29 +673,29 @@ static uint32 clean_up_driver_struct_level_3(NT_PRINTER_DRIVER_INFO_LEVEL_3 *dri
* or worse c:\windows\system\driver.dll !
*/
/* using an intermediate string to not have overlaping memcpy()'s */
- if ((p = strrchr(driver->driverpath,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->driverpath,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->driverpath, new_name);
}
- if ((p = strrchr(driver->datafile,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->datafile,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->datafile, new_name);
}
- if ((p = strrchr(driver->configfile,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->configfile,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->configfile, new_name);
}
- if ((p = strrchr(driver->helpfile,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->helpfile,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->helpfile, new_name);
}
if (driver->dependentfiles) {
for (i=0; *driver->dependentfiles[i]; i++) {
- if ((p = strrchr(driver->dependentfiles[i],'\\')) != NULL) {
+ if ((p = strrchr_m(driver->dependentfiles[i],'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->dependentfiles[i], new_name);
}
@@ -738,29 +738,29 @@ static uint32 clean_up_driver_struct_level_6(NT_PRINTER_DRIVER_INFO_LEVEL_6 *dri
* or worse c:\windows\system\driver.dll !
*/
/* using an intermediate string to not have overlaping memcpy()'s */
- if ((p = strrchr(driver->driverpath,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->driverpath,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->driverpath, new_name);
}
- if ((p = strrchr(driver->datafile,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->datafile,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->datafile, new_name);
}
- if ((p = strrchr(driver->configfile,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->configfile,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->configfile, new_name);
}
- if ((p = strrchr(driver->helpfile,'\\')) != NULL) {
+ if ((p = strrchr_m(driver->helpfile,'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->helpfile, new_name);
}
if (driver->dependentfiles) {
for (i=0; *driver->dependentfiles[i]; i++) {
- if ((p = strrchr(driver->dependentfiles[i],'\\')) != NULL) {
+ if ((p = strrchr_m(driver->dependentfiles[i],'\\')) != NULL) {
fstrcpy(new_name, p+1);
fstrcpy(driver->dependentfiles[i], new_name);
}
@@ -2292,7 +2292,7 @@ static void map_to_os2_driver(fstring drivername)
for( i = 0; i < numlines; i++) {
char *nt_name = lines[i];
- char *os2_name = strchr(nt_name,'=');
+ char *os2_name = strchr_m(nt_name,'=');
if (!os2_name)
continue;
@@ -2302,7 +2302,7 @@ static void map_to_os2_driver(fstring drivername)
while (isspace(*nt_name))
nt_name++;
- if (!*nt_name || strchr("#;",*nt_name))
+ if (!*nt_name || strchr_m("#;",*nt_name))
continue;
{
@@ -3189,7 +3189,7 @@ BOOL nt_printing_getsec(TALLOC_CTX *ctx, char *printername, SEC_DESC_BUF **secde
fstring key;
char *temp;
- if ((temp = strchr(printername + 2, '\\'))) {
+ if ((temp = strchr_m(printername + 2, '\\'))) {
printername = temp + 1;
}