| verzia 1.8, 2001/11/12 16:08:00 |
verzia 1.9, 2001/11/12 20:19:10 |
|
|
| /* |
/* |
| * Author: Lubomir Host 'rajo' <host8@kepler.fmph.uniba.sk> |
* Author: Lubomir Host 'rajo' <host8@kepler.fmph.uniba.sk> |
| * $Log$ |
* $Log$ |
| |
* Revision 1.9 2001/11/12 20:19:10 host8 |
| |
* http_connect() probably works fine. |
| |
* Some problems with http_requests for www.mtnsms.com. |
| |
* |
| * Revision 1.8 2001/11/12 16:08:00 host8 |
* Revision 1.8 2001/11/12 16:08:00 host8 |
| * Big improvements in http. connect() doesn't work correctly yet. |
* Big improvements in http. connect() doesn't work correctly yet. |
| * |
* |
|
|
| # include "config.h" |
# include "config.h" |
| #endif |
#endif |
| #include "mail2sms.h" |
#include "mail2sms.h" |
| |
#include "strings.h" |
| #define strrmeol(__s) strrmcr(strrmlf(__s)) |
|
| |
|
| // Function isnnumber() {{{ |
// Function isnnumber() {{{ |
| int isnnumber(char *str, int len) |
int isnnumber(char *str, int len) |
| Riadok 49 int isnnumber(char *str, int len) |
|
| Riadok 52 int isnnumber(char *str, int len) |
|
| return 1; |
return 1; |
| } // }}} |
} // }}} |
| // Function strdel() strrmlf() strrmcr() {{{ |
// Function strdel() strrmlf() strrmcr() {{{ |
| char *strdel(char *s) { |
char *strdel(char *s) |
| |
{ |
| register int i; |
register int i; |
| |
|
| for (i = 0; s[i] != '\0'; i++) |
for (i = 0; s[i] != '\0'; i++) |
| Riadok 57 char *strdel(char *s) { |
|
| Riadok 61 char *strdel(char *s) { |
|
| |
|
| return s; |
return s; |
| } |
} |
| char *strrmlf(char *s) { |
char *strrmlf(char *s) |
| |
{ |
| while (strchr(s, '\n') != NULL) |
while (strchr(s, '\n') != NULL) |
| strdel(strchr(s, '\n')); |
strdel(strchr(s, '\n')); |
| |
|
| return s; |
return s; |
| } |
} |
| |
|
| char *strrmcr(char *s) { |
char *strrmcr(char *s) |
| |
{ |
| while (strchr(s, '\r') != NULL) |
while (strchr(s, '\r') != NULL) |
| strdel(strchr(s, '\r')); |
strdel(strchr(s, '\r')); |
| |
|